PhysioVisualizer Data FormatThis document explain about the data formats that PhysioVisualizer can read and visualize.
Three data formatsPhysioVisualizer can read three types of data formats.
1. Orthogonal uniform grid (.vm and .fld)
1.1 Grid for all cubic area involving the target object
1.2 Grid for only the target object
2. Flint simulation data (.isd)
3. ImageViewer voxel selection data (.xml, .txt)
1. Orthogonal uniform grid
1.1. Orthogonal uniform grid: all cubic area involving the target objectThe data file with the suffix .vm is a binary file containing values for all voxels in a cubic space including an object targeted for visualization.
Voxels which correspond to the space out of the object (empty space) must have 0 value.
Voxels on the object are given values, which are described by char, short, int, float or double precisions.
It is possible to insert arbitrary length header describing free text, which will be skipped when PhysioDesigner reads the data file.
Following the header, the values are listed as (x0,y0,z0), ... , (x0,y0,z0), (x0,y1,z0),..., (xn,y1,z0),(x0,y2,z0),..., (xn,ym,z0),(x0,y0,z1),...,(xn,ym,zk).
Meta information of the data file must be given in a separate file with the suffix .fld. The meta information includes the following information.
ndim = 3
dim1 = 64
dim2 = 64
dim3 = 64
nspace = 3
veclen = 1
data = byte
field = uniform
variable 1 file=./h_v29_26000.vm filetype=binary skip=8
ndim: number of dimension for a computing space. For now, PhysioDesigner deals with data only with ndim=3.
dim1, dim2, dim3: division number for each axis. 1, 2, 3 correspond to x, y, z.
nspace: number of dimension for a physical space. For now, PhysioDesigner deals with data only with nspace=3.
veclen: number of data type on each grid point. For now, PhysioDesigner deals with data only with veclen=1.
data: precision of values. (short, byte, integer, float, double)
field: type of mesh (uniform, rectilinear, irregular)
uniform: Orthogonal equally spaced grid
rectilinear: Orthogonal non-equally spaced grid
irregular: Arbitrary grid
For now, PhysioVisualizer only supports "uniform"
variable: file: specifying the datafile
skip: length to skip the header in the datafile
Notice that VM and FLD files are the same format defined by CYBERNET SYSTEMS CO.,LTD for AVS. However PhysioVisulaizer parses only a part of the format.
1.2. Orthogonal uniform grid: only the target objectThe data file with the suffix .raw is a binary file containing values for voxels only on an object targeted for visualization.
Hence voxels which correspond to the space out of the object are not included in this data file. Hence the file size can be smaller, but it is impossible to specify the location of every voxels, that is, impossible to determine the shape.
Other part is the same with VM file described in the previous section.
A FLD meta information is not necessary in this case, instead data defining the exact shape of the object must be provided, which is written in VOL format or RAW format.
The RAW or VOL volume file includes all voxels not only on the object but also outside of the object.
2. Flint Simulation Data (.isd)PhysioDesigner can create a model using Template/Instances framework with volume morphological data.
Voxels in a VOL or RAW data file representing the morphology are replaced by instance modules. Every instance module records their position (coordinate) in its label.
Details how to create a model in that way is described in PhysioDesigner's site (http://physiodesigner.org).
Flint can execute a simulation of such models, and saves the output simulation data in a file with ISD binary format which includes the labels of the instance modules at the header part of the format.
Hence to visualize the ISD file, only the dimensions of the outer cubic space has to be provided.
The ISD file is once converted into VM files. Since ISD file includes data for multiple time steps, usually many VM files and corresponding FLD files are generated from one ISD file.
To convert from ISD to VM, it is required to provide the information how the values in ISD file are converted, more specifically, the following three information must be provided; the minimum and maximum values in the ISD file and value size to express the values in VM file.
For example, let's assume that the minimum and maximum values are set as -70 and 90. The value size is 1 byte (char) unsigned (i.e. 0 - 255). Then in this case the value -70 in the ISD file is mapped to 1 and 90 to 255. Values in between are scaled linearly between 1 to 255. Notice that 0 in a VM file corresponds to a transparent voxel representing a vacant space.
3. ImageViewer voxel selection data (.xml, .txt)On ImageViewer which is a application bundled in PhysioDesigner package, it is possible to select specific voxels on a volume data with RAW and VOL formats. The selected voxels can be exported in a text or XML formats. Let us call the files SV (standing for selected voxels) files.
PhysioVisualizer can load a SV file on a conditional layer. To load a SV file, users must create a data layer at first on which the volume data used to select voxels on ImageViewer must be loaded. Then create a conditional layer based on the data layer, and load the VS file.
This function can be used, for example, to specify a stimulation site on an object.