How do you determine the elementary particle's spin number? I know that electrons and protons have a spin of 1/2, whereas photons have a spin of 1,.
However, I do not know how this is determined? How is it determined?       
 A: Theoretical side of the question.
Fields have classification due to their transformations by the irreducible representations of the Lorentz group: an arbitrary representation of the Lorentz group can be built as $\mathbf S^(m, n) = \mathbf S^{n}_{1} \times S^{m}_{2}$, where $\mathbf S_{1, 2}$ is the $SU(2)$ or $SO(3)$ irreducible representation. Representations are characterized by two half-integer/integer numbers $\left(n, m \right)$, which are the max eigenvalues of the $SU(2)$ ($SO(3)$) operators and have dimensions $(2n + 1)\times (2m + 1)$ (or $(2n + 1)(2m + 1)$ degrees of freedom (in irreducible sense)). The sum of these numbers $n + m$ corresponds to the irreducible representation of the rotation operator, so, we have one of the definitions of spin and it's connection with the dimensions of the field.
Then, there is a connection between fields and particles. It is build by two equations (I can write these equations, if you want to know how exactly it is realized), which determine the realization of irreducible unitary representation of the Poincare group (i.e., one-particle state) by the irreducible representation of the Lorentz group. So, according to the classification of the fields by the Lorentz group representation, you can connect particle and spin of corresponding field.
For example, electromagnetic field represents as antisymmetrical tensor or as 4-vector (i.e, refers to one of the representations $(1, 0), (0, 1), \left( \frac{1}{2}, \frac{1}{2}\right)$). So, EM field has spin one. But it is massless, so it is characterized by helicity, which has meaning of projection of spin onto the direction of motion, not by spin.
Practical side of the question.
Your question is about theoretical aspect of spin determination, isn't it? In the case of negative answer, I'll add some info about the connection between polarization and helicity, connection between spin and statistics and other experimantal ways to get information about spin (helicity).
Bose and Einstein introduced the same name statistics in 1924-1926 years. First Bose used it for describing the photon gas state. Then Einstein generalized it into the atoms. Also, Dirac and Fermi created same name statistics in 1926, which first was applied for electrons in metals. Then Pauli in 1940 proved the correspondence between integer spin number particles and BE statistics and half-integer spin number particles and FD statistics. 
Correspondence between particles and their statistics can be observed experimentally. So we can say that particle from system of identical particles has integer or half-integer spin due to system's statistics. So, first, experimentally we can show, that photon gas corresponds to the integer spin.
Then, let's talk about helicity and polarization. Polarization can be interpreted as the  preferred orientation of the spin along the chosen direction. For the transverse spin polarization is perpendicular to the particle momentum, for the longitudinal polarization one is parallel. Helicity may have values $s, s - 1, ..., -s$. So, if you can measure the helicity of the particle, you also can tell some things about polarization, and vice versa (It requires a certain amount of theoretical knowledge). The experimental observations give two values of polarization of the photon - $1, -1$. According to the BE statistics of photon, it refers to the photons as spin(helicity)-one particles.
You can count up the number of spin values of the particle when it has some magnetic moment. For example, Stern-Gerlach experiment showed that electron has two spin degrees of freedom, so, according to applicability Fermi-Dirac statistics to it (to the system of electrons), it has spin $\frac{1}{2}$.
Also you can measure the spin (polarization) values of particles, if you know the spin of the other particle. For example, Maurive Goldhaber in 1958 measured the helicity of neutrino through photon helicity in the reaction of the $Eu^{152}_{63}$ decay. Similar methods are used in the analysis of particle collisions in CERN not only for determining spin (helicity) value, because the particles may have very small lifetime, or they don't have electric charge and we can't measure their number of spin freedom easy.
