Opened 7 years ago

Closed 7 years ago

#1600 closed defect (fixed)

Reading map: 'numpy.float64' object cannot be interpreted as an integer

Reported by: Elaine Meng Owned by: Tom Goddard
Priority: normal Milestone:
Component: Volume Data Version:
Keywords: Cc:
Blocked By: Blocking:
Notify when closed: Platform: all
Project: ChimeraX

Description

The following bug report has been submitted:
Platform:        Darwin-17.7.0-x86_64-i386-64bit
ChimeraX Version: 0.9 (2019-01-10)
Description
tried to use "move planes" mouse mode after choosing "orthoplanes" display in Volume Viewer

Log:
UCSF ChimeraX version: 0.9 (2019-01-10)  
How to cite UCSF ChimeraX  

> open "/Users/meng/Desktop/dicom/tcia/RIDER Lung
CT/RIDER-1129164940/11-06-2014-1-96508/4-24533/*.dcm" verbose true

Summary of feedback from opening files  
---  
notes | Data set: /Users/meng/Desktop/dicom/tcia/RIDER Lung
CT/RIDER-1129164940/11-06-2014-1-96508/4-24533/000080.dcm  
(0008, 0000) Group Length UL: 280  
(0008, 0005) Specific Character Set CS: 'ISO_IR 100'  
(0008, 0008) Image Type CS: ['ORIGINAL', 'PRIMARY', 'AXIAL']  
(0008, 0012) Instance Creation Date DA: '20060920'  
(0008, 0013) Instance Creation Time TM: '093833'  
(0008, 0016) SOP Class UID UI: CT Image Storage  
(0008, 0018) SOP Instance UID UI:
1.3.6.1.4.1.9328.50.1.80864899926417612544734009966266898264  
(0008, 0020) Study Date DA: '20060920'  
(0008, 0023) Content Date DA: '20060920'  
(0008, 0030) Study Time TM: ''  
(0008, 0033) Content Time TM: ''  
(0008, 0050) Accession Number SH: '1542750798412803'  
(0008, 0060) Modality CS: 'CT'  
(0008, 0070) Manufacturer LO: ''  
(0008, 0090) Referring Physician's Name PN: ' '  
(0010, 0000) Group Length UL: 62  
(0010, 0010) Patient's Name PN: '296698'  
(0010, 0020) Patient ID LO: 'RIDER-1129164940'  
(0010, 0030) Patient's Birth Date DA: '19461119'  
(0010, 0040) Patient's Sex CS: ''  
(0012, 0000) Group Length UL: 62  
(0012, 0062) Patient Identity Removed CS: 'YES'  
(0012, 0063) De-identification Method LO: 'CTP: DICOM-S142-Baseline:
20090626:165427'  
(0013, 0000) Private Creator UN: b'2\x00\x00\x00'  
(0013, 0010) Private tag data LO: 'CTP'  
(0013, 1010) Private tag data UN: b'RIDER Lung CT\x00'  
(0013, 1013) Private tag data UN: b'92033002'  
(0018, 0000) Group Length UL: 390  
(0018, 0010) Contrast/Bolus Agent LO: ''  
(0018, 0015) Body Part Examined CS: 'CHEST'  
(0018, 0022) Scan Options CS: 'HELICAL MODE'  
(0018, 0050) Slice Thickness DS: "1.250000"  
(0018, 0060) KVP DS: "120"  
(0018, 0090) Data Collection Diameter DS: "500.000000"  
(0018, 1100) Reconstruction Diameter DS: "295.000000"  
(0018, 1110) Distance Source to Detector DS: "949.075012"  
(0018, 1111) Distance Source to Patient DS: "541.000000"  
(0018, 1120) Gantry/Detector Tilt DS: "0.000000"  
(0018, 1130) Table Height DS: "127.400002"  
(0018, 1140) Rotation Direction CS: 'CW'  
(0018, 1150) Exposure Time IS: "505"  
(0018, 1151) X-Ray Tube Current IS: "399"  
(0018, 1152) Exposure IS: "9"  
(0018, 1160) Filter Type SH: 'BODY FILTER'  
(0018, 1170) Generator Power IS: "48000"  
(0018, 1190) Focal Spot(s) DS: "1.200000"  
(0018, 1210) Convolution Kernel SH: 'LUNG'  
(0018, 5100) Patient Position CS: 'FFS'  
(0018, 9305) Revolution Time FD: 0.5  
(0018, 9306) Single Collimation Width FD: 1.25  
(0018, 9307) Total Collimation Width FD: 20.0  
(0018, 9309) Table Speed FD: 55.0  
(0018, 9310) Table Feed per Rotation FD: 27.5  
(0018, 9311) Spiral Pitch Factor FD: 1.375  
(0020, 0000) Group Length UL: 378  
(0020, 000d) Study Instance UID UI:
1.3.6.1.4.1.9328.50.1.216116555221814778114703363464001196508  
(0020, 000e) Series Instance UID UI:
1.3.6.1.4.1.9328.50.1.83304264089411327530730818890072724533  
(0020, 0010) Study ID SH: ''  
(0020, 0011) Series Number IS: "4"  
(0020, 0012) Acquisition Number IS: "1"  
(0020, 0013) Instance Number IS: "2"  
(0020, 0032) Image Position (Patient) DS: ['-146.699997', '-155.300003',
'-36.250000']  
(0020, 0037) Image Orientation (Patient) DS: ['1.000000', '0.000000',
'0.000000', '0.000000', '1.000000', '0.000000']  
(0020, 0052) Frame of Reference UID UI:
1.3.6.1.4.1.9328.50.1.223115801243567643226232109211259092756  
(0020, 1040) Position Reference Indicator LO: 'SN'  
(0020, 1041) Slice Location DS: "-36.250000"  
(0028, 0000) Group Length UL: 182  
(0028, 0002) Samples per Pixel US: 1  
(0028, 0004) Photometric Interpretation CS: 'MONOCHROME2'  
(0028, 0010) Rows US: 512  
(0028, 0011) Columns US: 512  
(0028, 0030) Pixel Spacing DS: ['0.576172', '0.576172']  
(0028, 0100) Bits Allocated US: 16  
(0028, 0101) Bits Stored US: 16  
(0028, 0102) High Bit US: 15  
(0028, 0103) Pixel Representation US: 1  
(0028, 0120) Pixel Padding Value SS: -2000  
(0028, 1050) Window Center DS: "40"  
(0028, 1051) Window Width DS: "400"  
(0028, 1052) Rescale Intercept DS: "-1024"  
(0028, 1053) Rescale Slope DS: "1"  
(0028, 1054) Rescale Type LO: 'HU'  
(0040, 0000) Group Length UL: 30  
(0040, 0244) Performed Procedure Step Start Date DA: '20060920'  
(0040, 0245) Performed Procedure Step Start Time TM: '093136'  
(7fe0, 0010) Pixel Data OW: Array of 524288 bytes  
  
Opened RIDE 20060920, grid size 512,512,236, pixel 0.576,0.576,1.25, shown at
step 1, values int16  

> ui mousemode rightMode move planes

Traceback (most recent call last):  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/core/triggerset.py", line 130, in invoke  
return self._func(self._name, data)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/volume.py", line 3383, in _update_drawings  
v.update_drawings()  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/volume.py", line 659, in update_drawings  
self._keep_displayed_data = self.displayed_matrices()  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/volume.py", line 1592, in displayed_matrices  
matrices.append(self.matrix_plane(axis, omijk[axis], read_matrix))  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/volume.py", line 1185, in matrix_plane  
m = self.region_matrix((ijk_min, ijk_max, ijk_step), read_matrix)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/volume.py", line 1134, in region_matrix  
m = d.matrix(origin, size, step, progress, from_cache_only)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/data/griddata.py", line 248, in matrix  
m = self.read_matrix(ijk_origin, ijk_size, ijk_step, progress)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/data/dicom/dicom_grid.py", line 59, in read_matrix  
m = allocate_array(ijk_size, self.value_type, ijk_step, progress)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/data/readarray.py", line 203, in allocate_array  
m = alloc(shape, value_type)  
TypeError: 'numpy.float64' object cannot be interpreted as an integer  
  
Error processing trigger "graphics update": 'numpy.float64' object cannot be
interpreted as an integer:  
TypeError: 'numpy.float64' object cannot be interpreted as an integer  
  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/data/readarray.py", line 203, in allocate_array  
m = alloc(shape, value_type)  
  
See log for complete Python traceback.  
  
An error occurred in drawing the scene. Redrawing graphics is now stopped to
avoid a continuous stream of error messages. To restart graphics use the
command "graphics restart" after changing the settings that caused the error.  
  
Traceback (most recent call last):  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/core/updateloop.py", line 72, in draw_new_frame  
view.draw(check_for_changes = False)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/core/graphics/view.py", line 159, in draw  
self._draw_scene(camera, drawings)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/core/graphics/view.py", line 217, in _draw_scene  
draw_opaque(r, opaque_drawings)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/core/graphics/drawing.py", line 1360, in draw_opaque  
_draw_multiple(drawings, renderer, Drawing.OPAQUE_DRAW_PASS)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/core/graphics/drawing.py", line 1371, in _draw_multiple  
d.draw(renderer, draw_pass)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/grayscale.py", line 237, in draw  
pd = self.make_planes(axis)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/grayscale.py", line 298, in make_planes  
d = self.make_ortho_planes()  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/grayscale.py", line 340, in make_ortho_planes  
d = self.make_planes_drawing(planes)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/grayscale.py", line 373, in make_planes_drawing  
textures.append(self.texture_plane(k, axis))  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/grayscale.py", line 391, in texture_plane  
d = self.color_plane(k, axis)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/grayscale.py", line 409, in color_plane  
p = self.get_color_plane(axis, k)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/solid.py", line 211, in get_color_plane  
return self.color_values(axis, plane, cmap, cmap_range)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/solid.py", line 228, in color_values  
m = self.matrix_plane(axis, plane)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/volume.py", line 1185, in matrix_plane  
m = self.region_matrix((ijk_min, ijk_max, ijk_step), read_matrix)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/volume.py", line 1134, in region_matrix  
m = d.matrix(origin, size, step, progress, from_cache_only)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/data/griddata.py", line 248, in matrix  
m = self.read_matrix(ijk_origin, ijk_size, ijk_step, progress)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/data/dicom/dicom_grid.py", line 59, in read_matrix  
m = allocate_array(ijk_size, self.value_type, ijk_step, progress)  
File
"/Users/chimera/Applications/ChimeraX_Daily.app/Contents/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/chimerax/map/data/readarray.py", line 203, in allocate_array  
m = alloc(shape, value_type)  
TypeError: 'numpy.float64' object cannot be interpreted as an integer  
  




OpenGL version: 4.1 NVIDIA-10.32.0 355.11.10.10.40.102
OpenGL renderer: NVIDIA GeForce GTX 675MX OpenGL Engine
OpenGL vendor: NVIDIA Corporation

Change History (2)

comment:1 by pett, 7 years ago

Component: UnassignedVolume Data
Owner: set to Tom Goddard
Platform: all
Project: ChimeraX
Status: newassigned
Summary: ChimeraX bug report submissionReading map: 'numpy.float64' object cannot be interpreted as an integer

comment:2 by Tom Goddard, 7 years ago

Resolution: fixed
Status: assignedclosed

Fixed.

Move planes mouse mode in orthoplanes mode was broken because it was using a floating point plane number instead of an integer plane number.

Note: See TracTickets for help on using tickets.