kite icon indicating copy to clipboard operation
kite copied to clipboard

Exporting quadtree to csv failed

Open raghav413 opened this issue 2 years ago • 2 comments

Traceback (most recent call last): File "/home/raghav/gmt_sar/quadtree/test.py", line 33, in qt.export_csv('tree.csv') File "/usr/local/lib/python3.10/dist-packages/kite-1.5.0-py3.10-linux-x86_64.egg/kite/quadtree.py", line 1004, in export_csv "{lf.id}, {lf.focal_point[0]}, {lf.focal_point[1]}, " File "/usr/local/lib/python3.10/dist-packages/kite-1.5.0-py3.10-linux-x86_64.egg/kite/util/init.py", line 138, in cache_return instance.dict[var_name] = func(instance) File "/usr/local/lib/python3.10/dist-packages/kite-1.5.0-py3.10-linux-x86_64.egg/kite/quadtree.py", line 195, in theta theta = self.scene.theta[self._slice_rows, self._slice_cols] TypeError: 'float' object is not subscriptable

AND when I used spool to export quadtree as csv I get the following error

Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/kite-1.5.0-py3.10-linux-x86_64.egg/kite/spool/spool.py", line 318, in onExportQuadtree self.model.quadtree.export_csv(filename) File "/usr/local/lib/python3.10/dist-packages/kite-1.5.0-py3.10-linux-x86_64.egg/kite/quadtree.py", line 1003, in export_csv "{lf.id}, {lf.focal_point[0]}, {lf.focal_point[1]}, " File "/usr/local/lib/python3.10/dist-packages/kite-1.5.0-py3.10-linux-x86_64.egg/kite/util/init.py", line 138, in cache_return instance.dict[var_name] = func(instance) File "/usr/local/lib/python3.10/dist-packages/kite-1.5.0-py3.10-linux-x86_64.egg/kite/quadtree.py", line 194, in theta theta = self.scene.theta[self._slice_rows, self._slice_cols] IndexError: too many indices for array: array is 0-dimensional, but 2 were indexed

Please help

Thank you

raghav413 avatar Jul 27 '22 06:07 raghav413

Someone please help I am stuck there

raghav413 avatar Jul 29 '22 04:07 raghav413

Hi! What I can see from the limited information you provide is that you apparently only have a single scalar instead of a 2d array in your look-angle information. The heading and incidence angle arrays need to have the exact same size as the displacement array!

hvasbath avatar Jul 29 '22 07:07 hvasbath