what is the meaning of $|\Sigma|\cong \text{Hom}_{\text{Meas}}\;(X,2),$? In this answer to a question on math overflow the following is written: 

If $(X,\Sigma)$ is a measurable space,then one can identify $\Sigma$ with the set of measurable functions
  $$|\Sigma|\cong \text{Hom}_{\text{Meas}}\;(X,2),$$
  where $2$ is a two-point space with discrete $\sigma$-algebra.

I can see that there is a bijection between $\Sigma$ and Hom$_{\text{Meas}}(X,2)$ by taking the indicator functions of measurable sets but i don't understand what is the precise meaning of this isomorphism $$|\Sigma|\cong \text{Hom}_{\text{Meas}}\;(X,2),$$ Could someone please explain this to me?
 A: Let $\mathsf{Meas}$ be the category of measurable spaces, whose objects are pairs $(X, \Sigma)$ with $X$ a set and $\Sigma \subset \mathscr{P}(X)$ a $\sigma$-algebra on $X$. You have two functors from the category $\mathsf{Meas}$ to the category $\mathsf{Set}$ of sets:


*

*The first functor maps $(X, \Sigma)$ to the set $\Sigma$;

*The second functor maps $(X, \Sigma)$ to the hom-set $\operatorname{Hom}_{\mathsf{Meas}}((X,\Sigma), (\mathbf{2}, \mathscr{P}(\mathbf{2}))$, where $\mathbf{2} = \{0,1\}$ is a fixed set with two elements endowed with the discrete $\sigma$-algebra.


Then these two functors are (naturally) isomorphic. The isomorphism is given by:
\begin{align}
\theta_{(X,\Sigma)} : \operatorname{Hom}_{\mathsf{Meas}}((X,\Sigma), (2, \mathscr{P}(2)) & \to \Sigma \\
f & \mapsto f^{-1}(1)
\end{align}
This is easily seen to be an isomorphism, with inverse given by
\begin{align}
\theta_{(X,\Sigma)}^{-1} : \Sigma & \to \operatorname{Hom}_{\mathsf{Meas}}((X,\Sigma), (2, \mathscr{P}(2)) \\
A & \mapsto 1_A
\end{align}
where $1_A : X \to \mathbf{2}$ is the indicator function of $A \subset X$.
This is a natural transformation between the two functors, in other words, for all measurable maps $f : (X, \Sigma) \to (X', \Sigma')$, we have a commutative diagram:
$$\require{AMScd}
\begin{CD}
\operatorname{Hom}_{\mathsf{Meas}}((X',\Sigma'), (2, \mathscr{P}(2)) @>{f^*}>> \operatorname{Hom}_{\mathsf{Meas}}((X,\Sigma), (2, \mathscr{P}(2)) \\
@V{\theta_{(X', \Sigma')}}VV @V{\theta_{(X, \Sigma)}}VV \\
\Sigma' @>{f^{-1}(-)}>> \Sigma
\end{CD}$$
where
$$f^* : \operatorname{Hom}_{\mathsf{Meas}}((X',\Sigma'), (2, \mathscr{P}(2)) \to \operatorname{Hom}_{\mathsf{Meas}}((X,\Sigma), (2, \mathscr{P}(2))$$
is precomposition by $f$ and $f^{-1}(-) : \Sigma' \to \Sigma$ maps $A \in \Sigma'$ to $f^{-1}(A) \in \Sigma$.
So to conclude: for all $\sigma$-algebras $(X, \Sigma)$, the set $\Sigma$ is in bijection with the set $\operatorname{Hom}_{\mathsf{Meas}}((X,\Sigma), (2, \mathscr{P}(2))$. Since bijections are the isomorphisms of the category $\mathsf{Set}$, it makes sense to say that they are "isomorphic", keeping in mind that it just means that they're in bijection. But more than that, it's not just a random bijection for each measurable space: this bijection is natural with respect to the measurable space.
