Core dumping on large vertex set

Maneesh Yadav 97yadavm at scar.utoronto.ca
Sat Apr 8 03:41:25 EDT 2000


Hi all,
While still struggling to get VTK to work totally on my system (I still
have no idea why KSpline.py doesn't work) I was fooling around just to see
if I could write a little pdb (protien databank)  viewer..
The little code snippet of where I put in the data is here (I don't
understand it totally conceptually..I know PolyVertex is the visual type
of thing I am going to display and the grid.. maps float points to the
vtkPolyVertex?)

polyVertexPoints = vtkFloatPoints()
polyVertexPoints.SetNumberOfPoints(len(test.atoms)) i=0 for atom in
test.atoms:


polyVertexPoints.InsertPoint(i,atom.position[0],atom.position[1],atom.position[2])
 i=i+1
 
aPolyVertex = vtkPolyVertex()
aPolyVertex.GetPointIds().SetNumberOfIds(len(test.atoms)) print
len(test.atoms) i=0 for i in range(0,(len(test.atoms)-1),1):
 aPolyVertex.GetPointIds().SetId(i,i) aPolyVertexGrid =
vtkUnstructuredGrid() aPolyVertexGrid.Allocate(1,1)
aPolyVertexGrid.InsertNextCell(aPolyVertex.GetCellType(),
aPolyVertex.GetPointIds())
aPolyVertexGrid.SetPoints(polyVertexPoints)

(BTW I am kind of new to python also, so there might very well something
obviously wrong with the way I have the loops organized..feel free to
point it out)


Works great for small PDBs, but I core dump on a-hemolysin (20k atoms=20k
verticies). This is a little large I know, I have 256MB...am I
seriously mis-using the
data structures in anyway (is vtk meant to handle type of stuff and this
big?)

I would like to write a some molecular modelling applications in vtk as
the hard stuff is taken of for me :)..but am I making a catagoreical
mistake in using VTK for this type of app? 

--------------------------------------------------------------------
This is the private VTK discussion list. Please keep messages on-topic.
Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
<majordomo at public.kitware.com>. For help, send message body containing
"info vtkusers" to the same address.
--------------------------------------------------------------------



More information about the vtkusers mailing list