title: Python library for computing spatial derivatives of optical flow
body: <p>I'm trying to compute a differential image velocity invariants (e.g. curl, divergence, deformation, etc) from a video using OpenCV in Python. To do that, I need to compute the spatial derivatives in the x,y directions of the optical flow. Unfortunately, OpenCV only seems to supply the APIs for computing optical flow, not its derivative.</p>
  
  <p><strong>Are there any Python libraries out there for computing spatial derivatives of optical flow?</strong> I found this SO question that was somewhat similar <a href="https://stackoverflow.com/questions/7612018/lucas-kanade-optical-flow-direction-vector">Lucas Kanade Optical Flow, Direction Vector</a>, and there is code the person wrote for computing spatial derivatives, but if at all possible I'd love a library rather than writing the code myself. Any suggestions would be appreciated!</p>