[[-0.44486981846094426, -0.0021363672818559996, -0.03721181986487324, 46.62686084588364], [0.005235315303737166, -0.44485768384714863, -0.03704886912935894, 60.165881316857195], [-0.02001550497747565, -0.020260819840215893, 0.24044994416882276, 12.698317611104553], [0.0, 0.0, 0.0, 1.0]]
Transform.xfmis wrongly annotated asnpt.NDArray: https://github.com/gallantlab/pycortex/blob/main/cortex/xfm.py#L20It is a list because we construct
Transformdirectly with a JSON blob: https://github.com/gallantlab/pycortex/blob/main/cortex/database.py#L489For example:
Output:
Solution
Either fix the annotation to be
list[list[float]]or convert it tonp.ndarrayduring construction. I prefer the 2nd, but we need to check if that could mess up (de)serialization.