numpymatplotlibmultidimensional-arraytensorflowvisualize

How do I visualize or plot a multidimensional tensor?


I was wondering if anyone here has ever tried to visualize a multidimensional tensor in numpy. If so, could you share with me how I might go about doing this? I was thinking of reducing it to a 2D visualization.

I've included some sample output. It's weirdly structured, there are ellipses "..." and it's got a 4D tensor layout [[[[ content here]]]]

Sample Data:

[[[[ -9.37186633e-05  -9.89684777e-05  -8.97786958e-05 ...,
     -1.08984910e-04  -1.07056971e-04  -8.68257193e-05]
  [[ -9.61350961e-05  -8.75062251e-05  -9.39425736e-05 ...,
     -1.17737654e-04  -9.66376538e-05  -8.78447026e-05]
   [ -1.06558400e-04  -9.04031331e-05  -1.04479543e-04 ...,
     -1.02786013e-04  -1.07974607e-04  -1.07524407e-04]]
 [[[ -1.09648725e-04  -1.01073667e-04  -9.39013553e-05 ...,
     -8.94383265e-05  -9.06078858e-05  -9.83356076e-05]
   [ -9.76310257e-05  -1.04029998e-04  -1.01905476e-04 ...,
     -9.50643880e-05  -8.29156561e-05  -9.75912480e-05]]]
   [ -1.12038200e-04  -1.00154917e-04  -9.00980813e-05 ...,
     -1.10244124e-04  -1.16597665e-04  -1.10604939e-04]]]]

Solution