Apart from an inconsequential obvious typo regarding $s1/s2$ mapping, the problem with the above diagram is that it is incomplete, in the sense that although it is correct from a mathematical point of view, it does not convey the special nature of the Probability Mass function.
There are many functions that can be defined as having for domain the range of $X$. A subset of them will also have as their range $(0,1)$. But the PMF satisfies an additional critical condition, so as to function as a probability measure:
That it sums up (for discrete measures) or integrates (for absolutely continuous measures), or a little bit of both (for mixed measures), to unity.
Without this third condition it is not a probability mass function or a probability density function. And this critical condition is not reflected in the above diagram.