You have to correct your type map. Each type label has to be unique, but your dihedral map does not conform to that requirement. For example the following three lines:
1 X-C_2-C_3-X
2 X-C_2-C_3-X
3 X-C_2-C_3-X
will lead to X-C_2-C_3-X being mapped to type 3. The map to types 1 and 2 are overwritten.