[Paraview] Plot over time splitting on IDs
Eric E. Monson
emonson at cs.duke.edu
Thu May 29 15:10:39 EDT 2008
Hey Berk,
I may have tracked down what is going on with the time series getting
split according to index when you're trying to plot (extract) over
time using Global IDs:
In vtkExtractArraysOverTime::vtkInternal::AddTimeStepInternal(),
idsArray is being pulled from the data set using the name
"vtkOriginalPointIds". These IDs are being used as a key for the
extracted data (time series) blocks -- if the current key doesn't
exist, then a new block is created (and the time series is split).
The problem is that vtkExtractSelectedIdsCopyPoints() fills the
"vtkOriginalPointIds" array with indices, whether the
vtkSelection::ContentType() is GLOBALIDS or not. (GlobalIDs are copied
correctly along with the extracted data, but that's not what's put
into the new array.) It's unclear to me from the description of
vtkExtractSelectedIds whether this is the intended behavior...
So, I suspect that the desired fix would be to change something in
vtkExtractArraysOverTime.cxx, like adding these four lines below line
306 (but I don't know enough to figure out whether this would screw up
anything else):
if (this->ContentType == vtkSelection::GLOBALIDS)
{
idsArray = vtkIdTypeArray::SafeDownCast(inDSA->GetGlobalIds());
}
Thanks, and let me know what you think,
-Eric
On May 27, 2008, at 5:52 PM, Berk Geveci wrote:
> Hi Eric,
>
> This sounds like a bug to me too. I will investigate it soon.
>
> -berk
>
> On Tue, May 27, 2008 at 2:59 PM, Eric E. Monson
> <emonson at cs.duke.edu> wrote:
>> Hey All,
>>
>> I have a collection of vertices that represent biological cells in a
>> simulation, read into ParaView (cvs, OS X) as an unstructured grid.
>> Because
>> the number of cells in the sim changes over time, I have to use a
>> global ID
>> to keep track of cell identities for plotting, etc. Since the Xdmf
>> and XML
>> VTK formats do not assign real Global IDs, I set this using the
>> Python
>> Programmable Filter (GetPointData().SetGlobalIds()).
>>
>> If I want to plot some scalar over time I select a point, then
>> shift the
>> Selection Type to Global IDs in the Selection Inspector, then Create
>> Selection. I do the Copy Active Selection in Plot (Extract)
>> Selection Over
>> Time and the Copied Selection pane displays the proper Global ID.
>>
>> The problem is that the Plot Selection over time splits the time
>> series for
>> that Global ID every time the scalar ID (or whatever you call the
>> regular ID
>> or Index) for that vertex changes value. This results in a bunch of
>> blocks
>> listed under Root in the Select Block pane of the Extract Selection
>> Over
>> Time "Display" tab, all of them labeled with the same Global ID
>> (screen cap
>> attached). Checking the box next to any one of them displays the
>> short time
>> series in the plot, during which the scalar "ID" was constant.
>>
>> So, for some reason the filter seems to be splitting the data into
>> "Blocks"
>> based on scalar ID even when the selection is made based on Global
>> ID, and
>> the data for that Global ID exists for the complete time series.
>>
>> This seems like a bug to me, but please let me know if I'm just
>> misinterpreting something.
>>
>> Thanks,
>> -Eric
>>
>> ------------------------------------------------------
>> Eric E Monson
>> Duke Visualization Technology Group
>>
>>
>>
>>
>>
>> _______________________________________________
>> ParaView mailing list
>> ParaView at paraview.org
>> http://www.paraview.org/mailman/listinfo/paraview
>>
>>
More information about the ParaView
mailing list