2 Jan
2012
2 Jan
'12
3:40 p.m.
Hi, I've found a minor inconveniance using the flex type: test case: import numpy as np np_grid=np.double(np.zeros((3,7))) np_grid[1,3]=3.0 print(np_grid) # works print(np_grid[1,:]) # works from cctbx.array_family import flex grid=flex.double(flex.grid(3,7)) grid[1,3]=3.0 flex.show(grid) #works flex.show(grid[1,:]) #gives error (see below) "TypeError: All items must be of same type." Is there another simple way to do sclices with flex arrays or could this be implemented the same way as in numpy by someone who is more into c++ than myself? Thanks, Jan