Queen's University of Belfast
QUBPCCParallel Computer Centre

AVS

An Introduction course


Acknowledgement

The original document was compiled and typeset by Steve Larkin and Andy Grant, Computer Graphics Unit, Manchester Computing Centre. Additional exercises and improvements to the original text were supplied by Naomi Hill.

On site modifications have been completed by L. Geoghegan

Overview

Intro to AVS

Modules

Application Building
in the network editor

Network Editor

Network of Modules



Ex1 - Network editor

Geometry Viewer

Geometry viewer panel

Geom Objects

Manipulation of Objects

Alterations of the Lights

Composite objects

A composite scene



Software renderer

Hardware Renderers



Geometry Viewer

Ex2 - Geometry Viewer

Importing data into AVS

AVS Data Types

Field Data

Overall View

read_field module

Description of data

dimensions

Mapping methods

UNIFORM

Uniform mapping

Mapping methods

RECTILINEAR

Rectilinear mapping

Mapping methods

IRREGULAR

Irregular mapping

Format of the header file

	# AVS field file

Format

	This is a very very very very very -
	very long line.

Description of the data elements

	ndim=3		#number of computational dimensions
	dim1=40 	#dim of axis 1
	dim2=32 	# dim of axis 2
	dim3=32 	# dim of axis 3

	nspace=3 	number of coordinates per point
	veclen=3 	number of components at each point

	veclen		= 2
	label		= pressure				temperature
	unit		= kg/m**2				K

Reading the data

Operators to read data

Specifying the format
of the data

	variable N < number of format keywords >
	coord N < number of format keywords >

Format Keywords

Example 1: Image data

	0 10 0 15 200 255...
	...
	...

Solution for example 1

	# AVS field file
	#
	ndim = 2
	dim1 = 512
	dim2 = 256
	nspace = 2
	veclen = 1
	data = integer
	field = uniform
	variable 1 file=image.dat -
		filetype=ascii skip=0 stride=1

Example 2: Volume data

	Patient: Steve 10/11/93
	0 255 2 1 7.
	5 6.........
	...

Solution for example 2

	# AVS field file
	#
	ndim = 3
	dim1 = 128
	dim2 = 128
	dim3 = 128
	nspace = 3
	veclen = 1
	data = integer
	field = uniform
	variable 1 file=volume.dat filetype= 
		ascii skip=1 offset=0 stride=1

Example 3: Irregular data

The complete header file

# AVS field file
#
ndim = 2
dim1 = 5
dim2 = 10
nspace = 2
veclen = 2
data = float
field = irregular
label = temp press
variable 1 file=flow.dat filetype=ascii -
	skip=0 offset=0 stride=2 
variable 2 file=flow.dat filetype=ascii -
	skip=0 offset=1 stride=2
coord 1 file=coord.dat filetype=ascii -
	skip=0 offset=0 stride=2
coord 2 file=coord.dat filetype=ascii -
	skip=0 offset=1 stride=2

Debugging

The MRI Exercise

Importing the MRI data

Importing the MRI data

Example of colorizer

Temperature profile Exercise

Temperature profile



Modules

Example of field_to_mesh

2D field exercise

3D Arrays Exercise

	density x-mom y-mom z-mom stag x y z

Field descriptor

	ndim=
	dim1=
	dim2=
	dim3=
	nspace=
	veclen=
	data=
	field=
	variable 1 file=
	variable 2 file=
	variable 3 file=
	variable 4 file=
	variable 5 file=
	coord 1 file=
	coord 2 file=
	coord 3 file=

Visualising scalar components

Visualising vector components

volume_bounds module

hedgehog module

Example of hedgehog

3D field exercise

AVS command line options

AVS Command Line Interpreter (CLI)

A sample CLI script

net_clear
module "read image.user.0" -xy 230,73 -ex $Path/avs_library/mongo
module contrast.user.1 -xy 230,129 -ex $Path/avs_library/mongo
module "display image.user.2" -xy 230,185
port_connect "read image.user.0":0 contrast.user.1:0
port_connect contrast.user.1:0 "display image.user.2":0
parm_set "read image.user.0":"Read Image Browser"
usr/avs/data/image/avs.x
parm_set contrast.user.1:cont_in_max 178.171722412
parm_set contrast.user.1:cont_out_min 78.480216980

script -close

Obtaining hard copy from AVS

Practical uses

Customising AVS

	/usr/avs/runtime/avsrc

The .avsrc file

	Path /usr/local/avs
	NetworkDirectory /usr/avs/networks
	DataDirectory /usr/avs/data
	NoHW 1
	Bounding Box off

What is unstructured cell data?

How does AVS provide support?

A closer look at UCD

Importing UCD data

An example of a .inp file

	8 1 1 0 0
	1 0.0 0.0 1.0
	2 0.0 1.0 0.0
	...
	8 0.0 1.0 0.0
	1 1 hex 1 2 3 4 5 6 7 8
	1 1
	stress, lb/in**2
	1 499.999
	2 567.888
	...
	8 5000.00

A sample UCD network

Other modules

Closing Comments

We have covered!


All documents are the responsibility of, and copyright, © their authors and do not represent the views of The Parallel Computer Centre, nor of The Queen's University of Belfast.
Maintained by Alan Rea, email A.Rea@qub.ac.uk