scientific visualization using paraview
DESCRIPTION
Scientific Visualization Using ParaView. Robert Putnam [email protected]. Scientific Visualization Using ParaView – Summer 2013. Outline. Introduction ParaView overview ParaView/VTK data geometry/topology Case study Interactive session. Scientific Visualization Using ParaView – Summer 2013. - PowerPoint PPT PresentationTRANSCRIPT
![Page 1: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/1.jpg)
Scientific Visualization Using ParaViewScientific Visualization Using ParaView
Robert [email protected]
Scientific Visualization Using ParaView – Summer 2013
![Page 2: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/2.jpg)
OutlineOutline
• Introduction• ParaView overview• ParaView/VTK data geometry/topology• Case study• Interactive session
Scientific Visualization Using ParaView – Summer 2013
![Page 3: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/3.jpg)
IntroductionIntroduction
Scientific Visualization Using ParaView – Summer 2013
*Adapted from The ParaView Tutorial, Moreland
• Visualization: converting raw data to a form that is viewable and understandable to humans.
• Scientific visualization: specifically concerned with data that has a well-defined representation in 2D or 3D space (e.g., from simulation mesh or scanner).
![Page 4: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/4.jpg)
IntroductionIntroduction
Scientific Visualization Using ParaView – Summer 2013
• ParaView – open-source application designed for visualizing two- and three-dimensional data sets.
• Begun in 2000 as a collaboration between Kitware, Inc. and LANL (funded by DOE)• Built on VTK (“Visualization Tool Kit”)• Graphics user interface• Python scripting• Architecture extensible by plugins• Available for MS Windows, OSX, Linux• Support for large dataset / distributed architecture (client/server model)• Online and printed documentation from Kitware
![Page 5: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/5.jpg)
Generic visualization pipelineGeneric visualization pipeline
Scientific Visualization Using ParaView – Summer 2013
Source(s) Filters(s) Output (Rendering)
- - - - - - - - - - - - - - - - - - - - -
data/geometry/topology graphics
![Page 6: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/6.jpg)
Slice displaySlice display
Scientific Visualization Using ParaView – Summer 2013
heat.vtk (3D dataset)
Slice (2D)
Display
![Page 7: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/7.jpg)
Paraview user interfaceParaview user interface
Scientific Visualization Using ParaView – Summer 2013
Menu bar
Toolbars
Pipeline Browser
Object Inspector
3D View
![Page 8: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/8.jpg)
Combined filters to fileCombined filters to file
Scientific Visualization Using ParaView – Summer 2013
heat.vtk (3D dataset)
Slice Filterheat2.jpg
Stream Tracer
Tube Filter
Glyph Filter
scalar data
Vectordata
![Page 9: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/9.jpg)
Combined filters to fileCombined filters to file
Scientific Visualization Using ParaView – Summer 2013
heat.vtk Slice
StreamTube
Glyph
![Page 10: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/10.jpg)
ParaView – Pipeline BrowserParaView – Pipeline BrowserPipeline Browser
• located in the upper left corner of the user interface
• allows you to build a visualization pipeline
• allows you to interact with the current visualization pipeline
• top of the pipeline browser is the name of the server to which ParaView is connected
• below the server name is a tree structure representing each of the reader, source, and filter objects that are in the visualization pipeline.
Scientific Visualization Using ParaView – Summer 2013
![Page 11: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/11.jpg)
ParaView - Object InspectorParaView - Object Inspector– Object Inspector
• located beneath the Pipeline Browser in the user interface
• contains controls and information for the reader, source, or filter object selected in the Pipeline Browser
• allows you to interact with the current visualization pipeline
• content changes based upon the specific object selected
Scientific Visualization Using ParaView – Summer 2013
![Page 12: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/12.jpg)
Object Inspector - Properties Object Inspector - Properties – Object Inspector Tabs
• There are three tabs in the Object Inspector:
• Properties
• Display
• Information
• The Properties Tab contains controls for specifying various parameters of the object selected in the Pipeline Browser.
• Here is an example of what is shown in the Properties Tab for a Slice filter.
Scientific Visualization Using ParaView – Summer 2013
![Page 13: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/13.jpg)
Object Inspector - DisplayObject Inspector - Display– Object Inspector Tabs
• The Display Tab contains controls for setting the appearance of the object selected in the Pipeline Browser.
• grouped into several sections: View, Color, Slice, Style, Edge Style, Annotation, Lighting, and Transformation.
• Here is an example of what is shown in the Display Tab for a Slice filter.
Scientific Visualization Using ParaView – Summer 2013
![Page 14: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/14.jpg)
Object Inspector - InformationObject Inspector - Information– Object Inspector Tabs
• The Information Tab contains statistical information about the output of the object selected in the Pipeline Browser.
• Here is an example of what is shown in the Information Tab for a Slice filter.
Scientific Visualization Using ParaView – Summer 2013
![Page 15: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/15.jpg)
ParaView - MenusParaView - Menus
– File menu• handles various tasks such as opening data files,
saving data files, loading state files, saving state files, saving screenshots, saving animations, and fileserver connections.
Scientific Visualization Using ParaView – Summer 2013
![Page 16: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/16.jpg)
ParaView - MenusParaView - Menus
– View menu• allows you to modify the camera and center of rotation
for the 3D view. The view menu also allows you to toggle the visibility of the toolbars, inspectors, and views.
Scientific Visualization Using ParaView – Summer 2013
![Page 17: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/17.jpg)
ParaView - MenusParaView - Menus
– Filters menu• provides a list of available filters you can use to
process data sets.
• organized by recent, common, data analysis, temporal, and alphabetical.
• The most commonly used filters, located under the Common subdirectory, are also located on the Common Filters Toolbar.
• The filters are context sensitive and will only be available for selection if an appropriate data set has been loaded first and selected in the Pipeline Browser.
Scientific Visualization Using ParaView – Summer 2013
![Page 18: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/18.jpg)
ParaView - MenusParaView - Menus
– Help menu• provides information on the ParaView version,
information on client server connections, and provides access to the online manual.
• You can also visit the online version of the ParaView documentation: http://paraview.org/OnlineHelpCurrent/
Scientific Visualization Using ParaView – Summer 2013
![Page 19: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/19.jpg)
ParaView - HelpParaView - Help
Scientific Visualization Using ParaView – Summer 2013
![Page 20: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/20.jpg)
ParaView – Geometry v. ParaView – Geometry v. TopologyTopology Geometry of a dataset ~= points
Scientific Visualization Using ParaView – Summer 2013
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
Topology ~= connections among points, which define cells
So, what’s the topology here?
![Page 21: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/21.jpg)
ParaView – Geometry v. ParaView – Geometry v. TopologyTopology
Scientific Visualization Using ParaView – Summer 2013
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
![Page 22: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/22.jpg)
ParaView – Geometry v. ParaView – Geometry v. TopologyTopology
Scientific Visualization Using ParaView – Summer 2013
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
or
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
![Page 23: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/23.jpg)
ParaView – Geometry v. ParaView – Geometry v. TopologyTopology
Scientific Visualization Using ParaView – Summer 2013
or
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
or
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
![Page 24: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/24.jpg)
ParaView – Geometry v. ParaView – Geometry v. TopologyTopology
Scientific Visualization Using ParaView – Summer 2013
or
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
or
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
or
0,0 0,1 0,2 0,3
1,0 1,1 1,2 1,3
![Page 25: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/25.jpg)
Geometry/Topology StructureGeometry/Topology Structure Structure may be regular or irregular
– Regular (structured)• need to store only beginning position, spacing, number of points• smaller memory footprint per cell (topology can be generated on the fly)• examples: image data, rectilinear grid, structured grid
– Irregular (unstructured)• information can be represented more densely where it changes quickly • higher memory footprint (topology must be explicitly written) but more freedom• examples: polygonal data, unstructured grid
Scientific Visualization Using ParaView – Summer 2013
![Page 26: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/26.jpg)
Characteristics of DataCharacteristics of Data Data is organized into datasets for visualization
– Datasets consist of two pieces• organizing structure
– points (geometry)– cells (topology)
• data attributes associated with the structure– File format derived from organizing structure
Scientific Visualization Using ParaView – Summer 2013
Data is discrete– Interpolation functions generate data values in between known points
![Page 27: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/27.jpg)
Examples of Dataset TypesExamples of Dataset Types Structured Points (Image Data)
– regular in both topology and geometry– examples: lines, pixels, voxels– applications: imaging CT, MRI
Rectilinear Grid– regular topology but geometry only partially
regular– examples: pixels, voxels
Structured Grid (Curvilinear)– regular topology and irregular geometry– examples: quadrilaterals, hexahedron– applications: fluid flow, heat transfer
Scientific Visualization Using ParaView – Summer 2013
![Page 28: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/28.jpg)
Examples of Dataset Types (cont)Examples of Dataset Types (cont) Polygonal Data
– irregular in both topology and geometry– examples: vertices, polyvertices, lines,
polylines, polygons, triangle strips
Unstructured Grid – irregular in both topology and geometry– examples: any combination of cells– applications: finite element analysis,
structural design, vibration
Scientific Visualization Using ParaView – Summer 2013
![Page 29: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/29.jpg)
Examples of Cell TypesExamples of Cell Types
Scientific Visualization Using ParaView – Summer 2013
![Page 30: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/30.jpg)
Data AttributesData Attributes Data attributes associated with the organizing structure
– Scalars • single valued• examples: temperature, pressure, density, elevation
– Vectors• magnitude and direction• examples: velocity, momentum
– Normals • direction vectors (magnitude of 1) used for shading
– Texture Coordinates• used to map a point in Cartesian space into 1, 2, or 3D texture space• used for texture mapping
– Tensors • 3x3 only• examples: stress, strain
Scientific Visualization Using ParaView – Summer 2013
![Page 31: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/31.jpg)
File Format – Structured PointsFile Format – Structured Points
Scientific Visualization Using ParaView – Summer 2013
Editor structured-points.vtk:# vtk DataFile Version 3.0
first dataset
ASCII
DATASET STRUCTURED_POINTS
DIMENSIONS 3 4 5
ORIGIN 0 0 0
SPACING 1 1 2
POINT_DATA 60
SCALARS temp-point float
LOOKUP_TABLE default
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
![Page 32: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/32.jpg)
File Format – Structured PointsFile Format – Structured Points
Scientific Visualization Using ParaView – Summer 2013
Editor structured-points.vtk:# vtk DataFile Version 3.0
first dataset
ASCII
DATASET STRUCTURED_POINTS
DIMENSIONS 3 4 5
ORIGIN 0 0 0
SPACING 1 1 2
POINT_DATA 60
SCALARS temp-point float
LOOKUP_TABLE default
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
0 0 0 1 1 1 1 1 1 0 0 0
![Page 33: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/33.jpg)
File Format – Structured PointsFile Format – Structured Points
Scientific Visualization Using ParaView – Summer 2013
Editor structured-points.vtk:# vtk DataFile Version 3.0
first dataset
ASCII
DATASET STRUCTURED_POINTS
DIMENSIONS 3 4 5
ORIGIN 0 0 0
SPACING 1 1 2
CELL_DATA 24
SCALARS temp-cell float
LOOKUP_TABLE default
0 0 1 1 0 0
0 0 1 1 0 0
0 0 1 1 0 0
0 0 1 1 0 0
![Page 34: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/34.jpg)
File Format – Structured PointsFile Format – Structured Points
Scientific Visualization Using ParaView – Summer 2013
Editor structured-points.vtk:# vtk DataFile Version 3.0
first dataset
ASCII
DATASET STRUCTURED_POINTS
DIMENSIONS 3 4 5
ORIGIN 0 0 0
SPACING 1 1 2
CELL_DATA 24
SCALARS temp-cell float
LOOKUP_TABLE default
0 0 1 1 0 0
0 0 1 1 0 0
0 0 1 1 0 0
0 0 1 1 0 0
![Page 35: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/35.jpg)
Work flow – Case StudyWork flow – Case Study Student summer project: visualize MRI lung imagery
10 slices of 256x256 MATLAB
Read in data Noise removal, isolation of lung Some visualization
Scientific Visualization Using ParaView – Summer 2013
![Page 36: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/36.jpg)
Work flow – Case StudyWork flow – Case Study MATLAB -> VTK file
Write 256x256x10 float array to ASCII file:
Add header , save with ‘.vtk’ extension:
Scientific Visualization Using ParaView – Summer 2013
![Page 37: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/37.jpg)
Work flow – Case StudyWork flow – Case Study Read VTK file into Paraview, choose “Volume Visualization” display
option, add Clip Filter:
Scientific Visualization Using ParaView – Summer 2013
![Page 38: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/38.jpg)
Work flow – Case StudyWork flow – Case Study Change color map,
use Paraview animation feature to move clipping plane through volume:
Scientific Visualization Using ParaView – Summer 2013
![Page 39: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/39.jpg)
Work flow – Case StudyWork flow – Case Study
Produce movie Save animation from
Paraview, which produces image files (jpegs).
Read image files into Adobe Premiere Pro
Save as movie (.mov, .wmv, .avi. , etc.)
Scientific Visualization Using ParaView – Summer 2013
![Page 40: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/40.jpg)
Starting out - create sphereStarting out - create sphere
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Choose Sources -> Sphere
2. Click Apply in Object Inspector
3. User Interface:
- Undo
- Color
- Lighting
- Camera Movement
![Page 41: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/41.jpg)
Example – Loading dataExample – Loading data
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
which clears the pipeline
2. Open data file
File -> Open (cylinder.vtk)
3. Click Apply in Object Inspector
4. In Toolbar area (or Object Inspector /
Display), color by Pres. Show Legend.
5. Try Multi-view option (above upper right-hand corner of 3D window).
![Page 42: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/42.jpg)
Clipping, Cutting, SubsamplingClipping, Cutting, SubsamplingSelection Algorithms - Clipping
• can reveal internal details of surface• ParaView - Clip Filter
- Cutting/Slicing• cutting through a dataset with a surface• ParaView - Slice Filter
- Subsampling• reduces data size by selecting a subset of
the original data• ParaView - ExtractSubset Filter
Scientific Visualization Using ParaView – Summer 2013
![Page 43: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/43.jpg)
File Format – Structured GridFile Format – Structured Grid
Scientific Visualization Using ParaView – Summer 2013
Editor density.vtk:# vtk DataFile Version 3.0
vtk output
ASCII
DATASET STRUCTURED_GRID
DIMENSIONS 57 33 25
POINTS 47025 float
2.667 -3.77476 23.8329 2.94346 -3.74825 23.6656 3.21986 -3.72175 23.4982
3.50007 -3.70204 23.3738 3.9116 -3.72708 23.5319 4.1656 -3.69529 23.3312
. . .
POINT_DATA 47025
SCALARS Density float
LOOKUP_TABLE default
0.639897 0.239841 0.252319 0.255393 0.252118 0.246661 0.240134 0.234116 0.229199
0.225886 0.224268 0.224647 0.231496 0.246895 0.26417 0.27585 0.278987 0.274621
. . .
VECTORS Momentum float
0 0 0 13.753 -5.32483 -19.964 42.3106 -15.57 -43.0034
64.2447 -13.3958 -46.2281 73.7861 -4.83205 -36.3829 88.3374 6.23797 -22.8846
. . .
![Page 44: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/44.jpg)
Example – ClippingExample – Clipping
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (density.vtk)
3. Apply Clip filter to density.vtk
Click on density.vtk in pipeline
Filter -> Clip
![Page 45: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/45.jpg)
Example – Cutting/SlicingExample – Cutting/Slicing
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (density.vtk)
3. Apply Slice filter to density.vtk
Click on density.vtk in pipeline
Filter -> Slice
![Page 46: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/46.jpg)
Example – SubsamplingExample – Subsampling
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (density.vtk)
3. Apply Extract Subset filter to density.vtk
Click on density.vtk in pipeline
Filter -> Extract Subset
4. Apply Threshold filter to ExtractSubset
Click on ExtractSubset filter
Filter -> Threshold
![Page 47: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/47.jpg)
Color MappingColor Mapping Scalar Algorithms
– Color Mapping • maps scalar data to colors• implemented by using scalar values as an index into a color
lookup table
– ParaView • Color panel in Display tab of Object Inspector
– Color by– Edit Color Map
Scientific Visualization Using ParaView – Summer 2013
![Page 48: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/48.jpg)
Example – Color MappingExample – Color Mapping
Scientific Visualization Using ParaView – Summer 2013
1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (subset.vtk)
3. Go to the the color section in the Display Tab in the Object Inspector
The "Color by" menu lists the names of the attribute arrays. Selecting an array name causes the dataset’s coloring to be based on the underlying scalar values in that array.
![Page 49: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/49.jpg)
Example – Color Mapping (cont)Example – Color Mapping (cont)
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. The color map may be edited in the Color
Scale Editor window which appears when you click the Edit Color Map button in the Color section of the Display Tab.
2. Another way to change the mapping of data values to colors is by setting the Data Range.
-- The default Data Range is set from the minimum data value in the data set to the maximum data value.
-- Click on the Rescale Range button to explicitly set these values. The values between the minimum and maximum are then linearly interpolated into the color table.
![Page 50: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/50.jpg)
ContouringContouring Scalar Algorithms (cont)
– Contouring• construct a boundary between distinct regions, two steps:
– explore space to find points near contour– connect points into contour (2D) or surface (3D)
• 2D contour map (isoline):– applications: elevation contours from topography, pressure contours
(weather maps) from meteorology3D isosurface:• 3D isosurface:
– applications: tissue surfaces from tomography, constant pressure or temperature in fluid flow, implicit surfaces from math and CAD
– ParaView• Contour Filter
Scientific Visualization Using ParaView – Summer 2013
![Page 51: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/51.jpg)
Example – Isoline / 2D ContoursExample – Isoline / 2D Contours
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (subset.vtk)
3. Apply Contour filter to subset.vtk
click on subset.vtk in pipeline
Filter -> Contour
4. To color the contour line based upon its
scalar value and the current color map,
make sure the Compute Scalars
checkbox in the Contour section of the
Properties tab is selected
![Page 52: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/52.jpg)
Example – Isosurface / 3D ContoursExample – Isosurface / 3D Contours
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (density.vtk)
3. Apply Contour filter to density.vtk
click on density.vtk in pipeline
Filter -> Contour
4. Optional: apply Clip filter to output of Contour filter
![Page 53: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/53.jpg)
Scalar GenerationScalar Generation Scalar Algorithms (cont)
– Scalar Generation• extract scalars from part of data• example: extracting z coordinate (elevation) from terrain data to
create scalar values
– ParaView• Elevation Filter
Scientific Visualization Using ParaView – Summer 2013
![Page 54: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/54.jpg)
Example – Scalar GenerationExample – Scalar Generation
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (honolulu.vtk)
3. Apply Elevation filter to density.vtk
Click on honolulu.vtk in pipeline
Filter -> Elevation
4. Import ‘elevation.xml’ in color map
editor.
5. Animate high point(2) to simulate
changing sea level (e.g., [rising:
1050-5000] or [falling:1050-200)].
![Page 55: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/55.jpg)
Oriented GlyphsOriented Glyphs Vector Algorithms
– Oriented Glyphs• Orientation indicates direction• Length / color indicate magnitude, pressure,
temperature, etc.
– ParaView• Glyph Filter
– Set type to arrow
Scientific Visualization Using ParaView – Summer 2013
![Page 56: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/56.jpg)
Example – Oriented GlyphsExample – Oriented Glyphs
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Disconnect from Server
File -> Disconnect
2. Open data file
File -> Open (density.vtk)
3. Apply Glyph filter to density.vtk
click on density.vtk in pipeline
Filter -> Glyph
4. In the Object Inspector (Properties Tab)
set the “Scalars” menu to Density
set the “Vectors” menu to Momentum
set the “Glyph Type” to Arrow
![Page 57: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/57.jpg)
Field LinesField Lines Vector Algorithms (cont)
– Field Lines• Fluid flow is described by a vector field in three dimensions for steady (fixed time)
flows or four dimensions for unsteady (time varying) flows• Three techniques for determining flow
– Pathline (Trace)• tracks particle through unsteady (time-varying) flow• shows particle trajectories over time• rake releases particles from multiple positions at the same time instant• reveals compression, vorticity
– Streamline• tracks particle through steady (fixed-time) flow• holds flow steady at a fixed time• snapshot of flow at a given time instant
– Streakline• particles released from the same position over a time interval (time-varying)• snapshot of the variation of flow over time• example: dye steadily injected into fluid at a fixed point
Scientific Visualization Using ParaView – Summer 2013
![Page 58: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/58.jpg)
Field LinesField LinesStreamlines
• Lines show particle flow • ParaView - StreamTracer Filter
Streamlets• half way between streamlines and glyphs• ParaView - StreamTracer and Glyph Filters
Streamribbon• rake of two particles to create a ribbon• ParaView - StreamTracer and Ribbon Filters
Streamtube• circular rake of particles to create a tube• ParaView - StreamTracer and Tube Filters
Scientific Visualization Using ParaView – Summer 2013
![Page 59: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/59.jpg)
Stream Tracer FilterStream Tracer FilterStreamTracer Filter
• generates streamlines in vector field from collection of seed points
• first need to set up the integrator to do the numerical integration
• next need to specify the seeds points
Scientific Visualization Using ParaView – Summer 2013
![Page 60: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/60.jpg)
Example – StreamlinesExample – Streamlines
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Open data file
File -> Open (density.vtk)
2. Apply StreamTracer filter to density.vtk
Click on density.vtk in pipeline
Filter -> Stream Tracer
3. In the Object Inspector (Properties Tab)
Set “Vectors” menu to Momentum
Set “Max Propagation” to Time 100
Set “Initial Step Length” to Cell Length 0.1
Set “Integration Direction” to Both
Set “Max Steps” to 1000
Set “Integrator Type” to Runge-Kutta 4
Set “Seed Type” to Point Source,
Center on Bounds
Set “Number of Points” to 100
*Bonus: load state ‘streamline-glyph.pvsm’
![Page 61: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/61.jpg)
AnnotationAnnotationAnnotation
– used for annotating visualizations
– ParaView• Text Source
• Source -> Text
• Color Legend•“Edit Color Map” button in Display tab•“Show Color Legend” box in color legend tab of the Color Scale Editor
• Axes• Edit -> View Settings
Scientific Visualization Using ParaView – Summer 2013
![Page 62: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/62.jpg)
Example – AnnotationExample – Annotation
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Open data file
File -> Open (density.vtk)
2. Apply Clip filter to density.vtk
Click on density.vtk in pipeline
Filter -> Clip
3. Create a Text source
Sources -> Text
4. Turn on Color Legend
Edit Color Map for Clip in Display Tab
Color Legend tab in Color Scale Editor
Select “Show Color Legend” check box
5. Turn on orientation axis
Edit -> View Settings
Select “Orientation Axes” check box
![Page 63: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/63.jpg)
Saving ImagesSaving Images
Scientific Visualization Using ParaView – Summer 2013
Saving Images– common formats:
• jpg (lossy)• png (lossless) • pdf• tiff (lossless)
– ParaView• File -> Save Screenshot
![Page 64: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/64.jpg)
Example – Saving ImagesExample – Saving Images
Scientific Visualization Using ParaView – Summer 2013
ParaView:1. Open data file
File -> Open (density.vtk)
2. Apply Clip filter to density.vtk
click on density.vtk in pipeline
Filter -> Clip
3. Save Screenshot
File -> Save Screenshot
4. Set Resolution
5. Set File Type to JPG
![Page 65: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/65.jpg)
ParaView - ResourcesParaView - Resources
Scientific Visualization Using ParaView – Summer 2013
Tutorials– Using ParaView to Visualize Scientific Data scv.bu.edu/documentation/tutorials/ParaView/– ParaView Examples scv.bu.edu/documentation/software-help/scivis/paraview_examples/index.html-- “The Tutorial” www.paraview.org/Wiki/The_ParaView_Tutorial
Texts– The ParaView Guide, v3 Edition, Kitware, Inc, 2006.– The Visualization Toolkit, 4th Edition, Will Schroeder, Ken Martin, Bill Lorensen, Kitware ,
2006.
Websites– www.paraview.org– www.paraview.org/OnlineHelpCurrent/– www.paraview.org/Wiki/ParaView– www.kitware.com
![Page 66: Scientific Visualization Using ParaView](https://reader035.vdocument.in/reader035/viewer/2022062218/56816867550346895ddecd63/html5/thumbnails/66.jpg)
Questions?Questions? Tutorial survey:
- http://scv.bu.edu/survey/tutorial_evaluation.html
Scientific Visualization Using ParaView – Summer 2013