ZeitgeberH / patchview

python toolkits and GUI for multi-patch whole-cell data analysis and visualization
https://patchview.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
14 stars 4 forks source link

[JOSS review] Some morphology functionality is not available #10

Closed mstimberg closed 2 years ago

mstimberg commented 2 years ago

Loading the test.asc morphology, I am not able to use "Sholl analysis" (prints "To be done!" on the command line), and "Update Cell names" and "Distance to Pia" do not seem to work either (errors on the command line, see below). I am also not quite sure how to test the Plotting somas for a group of neurons functionality – does this require a single file with multiple cells in it? I tried loading the same cell several times, but this leads to a broken display.

Error for "Update Cell names" (after loading a cell three times):

Traceback (most recent call last):
  File "/mnt/data/miniforge3/envs/patchview/lib/python3.8/site-packages/patchview/patchview.py", line 6803, in morph_analysis_event
    self.updateInterCellDistance()
  File "/mnt/data/miniforge3/envs/patchview/lib/python3.8/site-packages/patchview/patchview.py", line 6747, in updateInterCellDistance
    summary.item(j, 9).value[p]
IndexError: invalid index to scalar variable.

Error for "Distance to Pia":

Traceback (most recent call last):
  File "/mnt/data/miniforge3/envs/patchview/lib/python3.8/site-packages/patchview/patchview.py", line 6805, in morph_analysis_event
    self.measureDist2Pia()
  File "/mnt/data/miniforge3/envs/patchview/lib/python3.8/site-packages/patchview/patchview.py", line 6765, in measureDist2Pia
    if self.pia is not None:
AttributeError: 'MainWindow' object has no attribute 'pia'

openjournals/joss-reviews#4706

ZeitgeberH commented 2 years ago

Hi, I've fixed "Sholl analysis" part. Please see documentation here. You are right about the Plotting somas for a group of neurons functionality. It only works for reconstruction file with multiple cells in it (like this one). Likewise, "Update Cell names" is only useful under this situation. "Distance to Pia" only works if the ASC file actually has an entry named "Pia" . Documentation of the these functions has been updated. Thanks!

mstimberg commented 2 years ago

I did a quick check with the provided files, and everything seems to work as intended now. Thanks.