Computing Jacobian Matrix

Hello. We have imported a python trained Keras model that does Image classification (CiFAR-10). I have verified the inference on our test images is equivalent.

For our research we need to obtain the Jacobian Matrix with respect to the input of a MultiLayerNetwork model to the outputs. (not with respect to the weights) Is there a existing method or approach that would achieve this using DL4J? Has anyone dones this before?

Our goal is to mimic the example shown here: computing-the-jacobian-matrix-of-a-neural-network-in-python
which demonstrates using Tensorflow or Autograd. Porting the Jacobian Matrix composition to Java would enable us to switch our analysis tools to Java/JavaFX which is desirable for the project.

I have figured out there is a gradients() and paramTable() API but I’m unclear which if either of these provide the values I need.