Method Of Characteristics(MOC) and Coarse-Mesh Finite Difference(CMFD) were adopted for the transport and accelerate calculation in the SONG code, which is capable of direct lattice calculation in library group structure. The geometry modules of SONG code implement the lattice based modular ray tracing for hexagonal or square lattice with pin-type or plate-type fuel elements. By modular programming and scientific data structure designing, the geometrical independent transport module and expansible geometry modules were developed. Geometry modules for different shape lattices share the uniform data interface with the transport module. The numerical results indicate that SONG code has the ability of treating the multiform lattices, and is with well performance in terms of precision, efficiency and stability.