Usually this means you have three colinear atoms for which the system is trying to compute a dihedral.
Look at your inputs and parameters to see if you’ve got three bonded colinear atoms, or bonded atoms that are defined with the same input coordinates the PDB file. You can fuzz the coordinates a bit so they aren’t perfectly colinear, and it should start working.
(Even if you are supposed to have a bunch of perfectly colinear atoms – fuzz them anyway, in the PDB and params if necessary. A 1% error in colinearity is enough to make dihedral math work and below the resolution of the PDB file anyway).