
Hi, I am having some trouble coloring my map based on segmentation. It used to be straightforward from the “Regions” menu of the segmentation tool, but now I am getting an error "TypeError: unsupported operand type(s) for *: 'float' and 'NoneType' File "/Applications/ChimeraX-1.7.1.app/Contents/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/chimerax/segger/regions.py", line 1884, in color_surface_pieces xyz = v - offset*n” I also tried to do it by line command but I confess I am not sure what to put for “seg-map”. Thank you for your help, Beth

Hi Beth, That looks like a bug in Segger. Hopefully you pressed the Report a Bug... button when it appeared. From the error message and looking at that line of code I see that the normal vectors for the surface of one of your regions is None. That probably means that region was never displayed. So I guess you have lots of regions and some are not displayed. There is an option in the Segment Map dialog that says "Display at most 60 regions" and you could probably fix your problem by increasing the 60 so that all your segmented regions are displayed. Tom
On Feb 5, 2024, at 8:43 AM, M. Elizabeth Stroupe via ChimeraX-users <chimerax-users@cgl.ucsf.edu> wrote:
Hi,
I am having some trouble coloring my map based on segmentation. It used to be straightforward from the “Regions” menu of the segmentation tool, but now I am getting an error
"TypeError: unsupported operand type(s) for *: 'float' and 'NoneType'
File "/Applications/ChimeraX-1.7.1.app/Contents/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/chimerax/segger/regions.py", line 1884, in color_surface_pieces xyz = v - offset*n”
I also tried to do it by line command but I confess I am not sure what to put for “seg-map”.
Thank you for your help,
Beth _______________________________________________ ChimeraX-users mailing list -- chimerax-users@cgl.ucsf.edu To unsubscribe send an email to chimerax-users-leave@cgl.ucsf.edu Archives: https://mail.cgl.ucsf.edu/mailman/archives/list/chimerax-users@cgl.ucsf.edu/

Hi Beth, Looking a bit more at the Segger code I see that the surface that is missing the normal vectors is actually the surface of the volume you are trying to color, not the surface of a segmented region. So the trouble is that a volume surface exists that has no normal vectors -- I'm guessing that is probably because the volume surface is empty because the threshold is set higher than the highest volume data value. All this is just guess work because I don't have much information about what you did to get this error. If you used the Report a Bug... button it will send the Log of the commands you ran and then I would have a better picture of what is going wrong. Tom
On Feb 5, 2024, at 10:22 AM, Tom Goddard <goddard@sonic.net> wrote:
Hi Beth,
That looks like a bug in Segger. Hopefully you pressed the Report a Bug... button when it appeared.
From the error message and looking at that line of code I see that the normal vectors for the surface of one of your regions is None. That probably means that region was never displayed. So I guess you have lots of regions and some are not displayed. There is an option in the Segment Map dialog that says "Display at most 60 regions" and you could probably fix your problem by increasing the 60 so that all your segmented regions are displayed.
Tom
On Feb 5, 2024, at 8:43 AM, M. Elizabeth Stroupe via ChimeraX-users <chimerax-users@cgl.ucsf.edu> wrote:
Hi,
I am having some trouble coloring my map based on segmentation. It used to be straightforward from the “Regions” menu of the segmentation tool, but now I am getting an error
"TypeError: unsupported operand type(s) for *: 'float' and 'NoneType'
File "/Applications/ChimeraX-1.7.1.app/Contents/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/chimerax/segger/regions.py", line 1884, in color_surface_pieces xyz = v - offset*n”
I also tried to do it by line command but I confess I am not sure what to put for “seg-map”.
Thank you for your help,
Beth _______________________________________________ ChimeraX-users mailing list -- chimerax-users@cgl.ucsf.edu To unsubscribe send an email to chimerax-users-leave@cgl.ucsf.edu Archives: https://mail.cgl.ucsf.edu/mailman/archives/list/chimerax-users@cgl.ucsf.edu/

Thank you, as always, for your prompt response. I just submitted the bug report along with the .seg file. I had grouped a lot of segmentations into just 3 - but yes, I had to use quite a lot of segments to get the proper domains segmented out as two are quite close. Beth On Feb 5, 2024, at 1:28 PM, Tom Goddard <goddard@sonic.net<mailto:goddard@sonic.net>> wrote: Hi Beth, Looking a bit more at the Segger code I see that the surface that is missing the normal vectors is actually the surface of the volume you are trying to color, not the surface of a segmented region. So the trouble is that a volume surface exists that has no normal vectors -- I'm guessing that is probably because the volume surface is empty because the threshold is set higher than the highest volume data value. All this is just guess work because I don't have much information about what you did to get this error. If you used the Report a Bug... button it will send the Log of the commands you ran and then I would have a better picture of what is going wrong. Tom On Feb 5, 2024, at 10:22 AM, Tom Goddard <goddard@sonic.net<mailto:goddard@sonic.net>> wrote: Hi Beth, That looks like a bug in Segger. Hopefully you pressed the Report a Bug... button when it appeared. From the error message and looking at that line of code I see that the normal vectors for the surface of one of your regions is None. That probably means that region was never displayed. So I guess you have lots of regions and some are not displayed. There is an option in the Segment Map dialog that says "Display at most 60 regions" and you could probably fix your problem by increasing the 60 so that all your segmented regions are displayed. Tom On Feb 5, 2024, at 8:43 AM, M. Elizabeth Stroupe via ChimeraX-users <chimerax-users@cgl.ucsf.edu<mailto:chimerax-users@cgl.ucsf.edu>> wrote: Hi, I am having some trouble coloring my map based on segmentation. It used to be straightforward from the “Regions” menu of the segmentation tool, but now I am getting an error "TypeError: unsupported operand type(s) for *: 'float' and 'NoneType' File "/Applications/ChimeraX-1.7.1.app/Contents/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/chimerax/segger/regions.py", line 1884, in color_surface_pieces xyz = v - offset*n” I also tried to do it by line command but I confess I am not sure what to put for “seg-map”. Thank you for your help, Beth _______________________________________________ ChimeraX-users mailing list -- chimerax-users@cgl.ucsf.edu<mailto:chimerax-users@cgl.ucsf.edu> To unsubscribe send an email to chimerax-users-leave@cgl.ucsf.edu<mailto:chimerax-users-leave@cgl.ucsf.edu> Archives: https://mail.cgl.ucsf.edu/mailman/archives/list/chimerax-users@cgl.ucsf.edu/<https://urldefense.com/v3/__https://mail.cgl.ucsf.edu/mailman/archives/list/chimerax-users@cgl.ucsf.edu/__;!!PhOWcWs!z-b9s0OflzBMsKPiz91z8xM1xZRJXAQyBUFv-_N5hmfJWeW2qM_E8p7pRSaER7RXB-Hbjj3Y-p69Llk$>

Hi Beth, Ok, I fixed the Segger bug. It was trying to color a volume surface which had not been calculated. The volume surfaces are only calculated when they are displayed, and this volume was restored from a session undisplayed. If you showed the volume before coloring you would not get this error. But it is a bug and I fixed the Segger code so that if the surface is not calculated it simply does not color it and does not produce an error. Details here https://www.rbvi.ucsf.edu/trac/ChimeraX/ticket/14539 Tom
On Feb 5, 2024, at 10:33 AM, M. Elizabeth Stroupe <mstroupe@fsu.edu> wrote:
Thank you, as always, for your prompt response.
I just submitted the bug report along with the .seg file.
I had grouped a lot of segmentations into just 3 - but yes, I had to use quite a lot of segments to get the proper domains segmented out as two are quite close.
Beth
On Feb 5, 2024, at 1:28 PM, Tom Goddard <goddard@sonic.net <mailto:goddard@sonic.net>> wrote:
Hi Beth,
Looking a bit more at the Segger code I see that the surface that is missing the normal vectors is actually the surface of the volume you are trying to color, not the surface of a segmented region. So the trouble is that a volume surface exists that has no normal vectors -- I'm guessing that is probably because the volume surface is empty because the threshold is set higher than the highest volume data value. All this is just guess work because I don't have much information about what you did to get this error. If you used the Report a Bug... button it will send the Log of the commands you ran and then I would have a better picture of what is going wrong.
Tom
On Feb 5, 2024, at 10:22 AM, Tom Goddard <goddard@sonic.net <mailto:goddard@sonic.net>> wrote:
Hi Beth,
That looks like a bug in Segger. Hopefully you pressed the Report a Bug... button when it appeared.
From the error message and looking at that line of code I see that the normal vectors for the surface of one of your regions is None. That probably means that region was never displayed. So I guess you have lots of regions and some are not displayed. There is an option in the Segment Map dialog that says "Display at most 60 regions" and you could probably fix your problem by increasing the 60 so that all your segmented regions are displayed.
Tom
On Feb 5, 2024, at 8:43 AM, M. Elizabeth Stroupe via ChimeraX-users <chimerax-users@cgl.ucsf.edu <mailto:chimerax-users@cgl.ucsf.edu>> wrote:
Hi,
I am having some trouble coloring my map based on segmentation. It used to be straightforward from the “Regions” menu of the segmentation tool, but now I am getting an error
"TypeError: unsupported operand type(s) for *: 'float' and 'NoneType'
File "/Applications/ChimeraX-1.7.1.app/Contents/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/chimerax/segger/regions.py", line 1884, in color_surface_pieces xyz = v - offset*n”
I also tried to do it by line command but I confess I am not sure what to put for “seg-map”.
Thank you for your help,
Beth _______________________________________________ ChimeraX-users mailing list -- chimerax-users@cgl.ucsf.edu <mailto:chimerax-users@cgl.ucsf.edu> To unsubscribe send an email to chimerax-users-leave@cgl.ucsf.edu <mailto:chimerax-users-leave@cgl.ucsf.edu> Archives: https://mail.cgl.ucsf.edu/mailman/archives/list/chimerax-users@cgl.ucsf.edu/ <https://urldefense.com/v3/__https://mail.cgl.ucsf.edu/mailman/archives/list/...>
participants (2)
-
M. Elizabeth Stroupe
-
Tom Goddard