Difference between revisions of "ParaView/Tricks"
From PHASTA Wiki
(Created page with "This page contains a list of tips and tricks for ParaView, which may be useful for others. ==Difference Between Two Timesteps== To look at the "delta" between two timesteps,...") |
(→Difference Between Two Timesteps) |
||
Line 4: | Line 4: | ||
To look at the "delta" between two timesteps, follow these steps. | To look at the "delta" between two timesteps, follow these steps. | ||
# Load your data file twice, so your pipeline browser has two separate instances of "flow.pht" or whatever file you open. | # Load your data file twice, so your pipeline browser has two separate instances of "flow.pht" or whatever file you open. | ||
− | # Apply one Force Time filter to each input file, and specify the physical time (not time index) for each. This will | + | # Apply one Force Time filter to each input file, and specify the physical time (not time index) for each. This will force the time for each and make them independent of the global ParaView time control in the upper toolbar. |
# Select both Force Time filters simultaneously, and apply a Programmable Filter. Your pipeline browser will now show arrows representing multiple inputs to the single programmable filter. | # Select both Force Time filters simultaneously, and apply a Programmable Filter. Your pipeline browser will now show arrows representing multiple inputs to the single programmable filter. | ||
# Populate the programmable filter with the following code:<br><code>tmp = inputs[0].PointData['myAvailableFieldName'] - inputs[1].PointData['myAvailableFieldName']<br>output.PointData.append(tmp, 'delta of myAvailableFieldName')</code> | # Populate the programmable filter with the following code:<br><code>tmp = inputs[0].PointData['myAvailableFieldName'] - inputs[1].PointData['myAvailableFieldName']<br>output.PointData.append(tmp, 'delta of myAvailableFieldName')</code> | ||
# You can now view the field, "delta of myAvailableFieldName," and change the time steps it uses to compute the time-delta by modifying the Force Time filter properties. | # You can now view the field, "delta of myAvailableFieldName," and change the time steps it uses to compute the time-delta by modifying the Force Time filter properties. |
Revision as of 10:25, 15 August 2017
This page contains a list of tips and tricks for ParaView, which may be useful for others.
Difference Between Two Timesteps
To look at the "delta" between two timesteps, follow these steps.
- Load your data file twice, so your pipeline browser has two separate instances of "flow.pht" or whatever file you open.
- Apply one Force Time filter to each input file, and specify the physical time (not time index) for each. This will force the time for each and make them independent of the global ParaView time control in the upper toolbar.
- Select both Force Time filters simultaneously, and apply a Programmable Filter. Your pipeline browser will now show arrows representing multiple inputs to the single programmable filter.
- Populate the programmable filter with the following code:
tmp = inputs[0].PointData['myAvailableFieldName'] - inputs[1].PointData['myAvailableFieldName']
output.PointData.append(tmp, 'delta of myAvailableFieldName') - You can now view the field, "delta of myAvailableFieldName," and change the time steps it uses to compute the time-delta by modifying the Force Time filter properties.