View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0007453ParaView(No Category)public2008-08-05 18:032009-05-13 13:46
Reporterolesen 
Assigned ToZhanping Liu 
PrioritynormalSeveritycrashReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target Version3.6Fixed in Version 
Summary0007453: Ensight measured data crash paraview.
DescriptionReading ensight gold with measured data in ASCII format crashes paraview while attempting to assign the points:

vtkEnSightGoldReader::ReadMeasuredGeometryFile()
{
...
  vtkDebugMacro("assign points");
  geom->SetPoints(newPoints); // CRASH!
  vtkDebugMacro("assigned points");
  newPoints->Delete();
  vtkDebugMacro("newPoints->Deleted");

  ...
}

NOTE: in the prev code snippet, I already had to replace the
  geom->InsertNextCell(VTK_VERTEX, 1, &id);

with
  vtkCellArray *newCells = vtkCellArray::New();
  newCells->Allocate(this->NumberOfMeasuredPoints);
  ...
  for (...)
    {
    newCells->InsertNextCell(1, &id);
    }

to avoid another crash.



Reading in binary files fails differently. Here the culprit is apparently from re-using the same block:

Debug: In .../VTK/IO/vtkEnSightGoldBinaryReader.cxx, line 1145
vtkEnSightGoldBinaryReader (0x17b6060): read measured data - add to block

ERROR: In .../VTK/IO/vtkEnSightReader.cxx, line 2145
vtkEnSightGoldBinaryReader (0x17b6060): Block already has a vtkDataSet assigned to it.

Debug: In .../VTK/IO/vtkEnSightGoldBinaryReader.cxx, line 1152
vtkEnSightGoldBinaryReader (0x17b6060): added to block


Looking at the code in vtkEnSightGoldBinaryReader.cxx, line 1150

  this->AddToBlock(output, this->NumberOfGeometryParts, pd);

It looks like the last geometry part is getting reused.
In the ReadMeasuredGeometryFile() there is no signs of the output dataset being incremented.


The attached cases are a minimal set of data that reproduces the problem.

TagsNo tags attached.
Project
Topic Name
Type
Attached Filesbz2 file icon ensightMeasuredData.tar.bz2 [^] (253,640 bytes) 2008-08-05 18:03
txt file icon Patch7453.txt [^] (2,850 bytes) 2009-03-23 13:28 [Show Content]

 Relationships

  Notes
(0015764)
Zhanping Liu (developer)
2009-03-23 13:25

The bug has been fixed and the problem was due to the lack of updating (incrementing) of the number of geoemtry parts (this->NumberOfGeometryParts) as they are extracted in vtkEnSightGoldBinaryReader::ReadGeometryFile. After the fix, the measured geometry can be properly combined into a vtkMultiBlockDataSet object.

There were still two additional bugs (#A and #B) even with the added code for updating the aforementioned counter. Bug #A causes the measured geometry to be incorrectly interpreted due to the 1-based indexing scheme ALWAYS used in EnSight. In other words, "this->ParticleCoordinatesByIndex" needs to be, and was, removed from vtkEnSightGoldBinaryReader::ReadMeasuredGeometryFile().

Bug #B causes the measured scalars (associated with the measured geometry) to be incorrectly read due to a redundant use of this->ReadLine(line) in vtkEnSightGoldBinaryReader::ReadScalarsPerNode().

All of these three related bugs have been fixed and both the binary and ASCII versions of the provided sample dataset work well with the fix.

Please see the atatched patch file for detail.

new revision: 1.79; previous revision: 1.78
(0015765)
Zhanping Liu (developer)
2009-03-23 13:27

BTW, the reported problem with the ASCII version does not exist even before my fix. It was fixed some time by somebody else after your report (Aug 2008).
(0015770)
Alan Scott (manager)
2009-03-23 19:44

Tested client/remote server.

 Issue History
Date Modified Username Field Change
2008-08-05 18:03 olesen New Issue
2008-08-05 18:03 olesen File Added: ensightMeasuredData.tar.bz2
2008-08-21 13:55 Utkarsh Ayachit Status backlog => tabled
2008-08-21 13:55 Utkarsh Ayachit Assigned To => Berk Geveci
2009-02-18 09:04 Utkarsh Ayachit Category 3.4 => 3.6
2009-03-18 13:36 Berk Geveci Assigned To Berk Geveci => Zhanping Liu
2009-03-23 13:25 Zhanping Liu Note Added: 0015764
2009-03-23 13:27 Zhanping Liu Note Added: 0015765
2009-03-23 13:28 Zhanping Liu File Added: Patch7453.txt
2009-03-23 13:29 Zhanping Liu Status tabled => @80@
2009-03-23 19:44 Alan Scott Note Added: 0015770
2009-03-23 19:44 Alan Scott Status @80@ => closed
2009-03-23 19:44 Alan Scott Resolution open => fixed
2009-05-13 13:46 Utkarsh Ayachit Target Version => 3.6
2011-06-16 13:10 Zack Galbreath Category => (No Category)


Copyright © 2000 - 2018 MantisBT Team