Hi!
I am developing a software using pyqtgraph which uses the ROI capabilities 
to create mask for area detectors. Everything works when the bounding 
rectangle of the  ROIs are less than 1000. But recently I had to work with 
some of the detectors which are large in size i.e 2000X2000 pixels and 
sometimes I need to create mask using polyline ROI, the bounding rectangle 
of which may become larger than 1000. Once the bounding rectangle becomes 
larger than 1000 the ROI.getArrayRegion crashes giving an exception as 
shown below:

Traceback (most recent call last):
  File "C:\Users\Mrinal Bera\Documents\Visual Studio 
2017\Projects\XRTools\XRTools\maskWidget.py", line 260, in create_all_masks
    self.create_mask(key)
  File "C:\Users\Mrinal Bera\Documents\Visual Studio 
2017\Projects\XRTools\XRTools\maskWidget.py", line 237, in create_mask
    mpossx=self.mask[mask_number].getArrayRegion(possx,self.pg_image)
  File "C:\Program 
Files\Anaconda3\lib\site-packages\pyqtgraph\graphicsItems\ROI.py", line 
2025, in getArrayRegion
    raise Exception()
Exception

As per the exception raised in line 2025 of ROI.getArrayRegion method there 
is indeed an exception for bounding rectangle larger than 1000. This 
exception only raises with polylineROIs. 

My question to Luke or any other who knows about this is: Is there any 
reason for this exception to be put in explicitly? Can I get around this 
exception by any other means without commenting the lines 2024-2025 of 
ROI.getArrayRegion method?

Thanks in Advance!

Best,
Mrinal

-- 
You received this message because you are subscribed to the Google Groups 
"pyqtgraph" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pyqtgraph/e4dc6d8c-08b4-4667-966f-f60dd9a12cb3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to