Closed sfritzs closed 1 month ago
obtained same error, I loaded files, I gated a couple of channels, saving the gates, when clicking plot points it fails
reloading plugin after error does not help
I load files, go to sample 10, gate ecad, plot points, save gate, go to IDO, gate, plot points, save gate. Go to panCK, gate, plot points -> FAILS here.
@melonora I have seen this error pop up many times in Napari issues, so I will stop testing for now to hear your opinion. My guess is there is a memory handling issue.
Jose here testing a bit more. I do not think it is a memory issue. I just spent 10min or so (before error in 30 seconds or so) changing markers and samples. Visualizing. The error starts as soon as I plot points for a second sample/marker combination.
I could plot as many point as I wanted for one sample/marker combination. Both as soon as I switch and plot points for another sample/marker combination it fails. All of this without saving any gates, loading or saving the dataframe.
Jose in macOS, I tested thoroughly and cant seem to run into error in MacOS... I will focus on Windows Workstation to understand what is failing
update: Ran the plugin in a different windows machine and it works. with both cylinter demo dataset, and the large HN dataset. I think the problem is then with that specific machine.
@melonora
It seems that the point already was being cleared everytime the marker and sample was being loaded. Any other ideas of what it could be?
def _load_images_and_scatter_plot(self):
self._clear_layers(clear_all=True)
self._read_data(self.model.active_sample)
# active marker is a string
# markers is dict with marker_name_string:index (based on dropdowns)
self._load_layers(self.model.markers_image_indices[self.model.active_marker])
logger.debug(f"loading index {self.model.markers_image_indices[self.model.active_marker]}")
self.update_plot()
self.update_slider()
def _clear_layers(self, clear_all: bool) -> None:
"""Remove all layers upon changing sample."""
if clear_all is True:
self.viewer.layers.select_all()
self.viewer.layers.remove_selected()
else:
for layer in self.viewer.layers:
if isinstance(layer, Image):
self.viewer.layers.remove(layer)
close for now, but could come up again
Another one :) getting closer