General and interpretable models for inferring dynamical computation in biological neural networks