A continuum model for a population of self-propelled particles interacting through nematic alignment is derived from an individual-based model. The methodology consists of introducing a hydrodynamic scaling of the corresponding mean field kinetic equation. The resulting perturbation problem is solved thanks to the concept of generalized collision invariants. It yields a hyperbolic but nonconservative system of equations for the nematic mean direction of the flow and the densities of particles flowing parallel or antiparallel to this mean direction. An application to myxobacteria is presented.