Table of Contents

Class HDF5

Namespace
Emgu.CV.Hdf
Assembly
Emgu.CV.dll

Hierarchical Data Format version 5 interface.

public class HDF5 : SharedPtrObject, IDisposable
Inheritance
HDF5
Implements
Inherited Members

Constructors

HDF5(string)

Open or create hdf5 file.

public HDF5(string fileName)

Parameters

fileName string

Specify the HDF5 filename.

Methods

AtDelete(string)

Delete an attribute from the root group.

public void AtDelete(string atLabel)

Parameters

atLabel string

The attribute to be deleted.

AtExists(string)

Check whether a given attribute exits or not in the root group.

public bool AtExists(string atLabel)

Parameters

atLabel string

The attribute name to be checked.

Returns

bool

True if the attribute exists, False otherwise.

AtReadArray(IOutputArray, string)

Read an attribute from the root group.

public void AtReadArray(IOutputArray array, string atLabel)

Parameters

array IOutputArray

The output value

atLabel string

Attribute name

AtReadDouble(string)

Read an attribute from the root group.

public double AtReadDouble(string atLabel)

Parameters

atLabel string

Attribute name

Returns

double

The double value

AtReadInt(string)

Read an attribute from the root group.

public int AtReadInt(string atLabel)

Parameters

atLabel string

Attribute name

Returns

int

The int value

AtReadString(string)

Read an attribute from the root group.

public string AtReadString(string atLabel)

Parameters

atLabel string

Attribute name

Returns

string

The String value

AtWrite(IInputArray, string)

Write an attribute inside the root group.

public void AtWrite(IInputArray value, string atLabel)

Parameters

value IInputArray

Attribute value.

atLabel string

Attribute name.

AtWrite(double, string)

Write an attribute inside the root group.

public void AtWrite(double value, string atLabel)

Parameters

value double

Attribute value.

atLabel string

Attribute name.

AtWrite(int, string)

Write an attribute inside the root group.

public void AtWrite(int value, string atLabel)

Parameters

value int

Attribute value.

atLabel string

Attribute name.

AtWrite(string, string)

Write an attribute inside the root group.

public void AtWrite(string value, string atLabel)

Parameters

value string

Attribute value.

atLabel string

Attribute name.

Close()

Close and release hdf5 object.

public void Close()

DisposeObject()

Release all the unmanaged memory associate with this object

protected override void DisposeObject()

DsCreate(int, int, DepthType, int, string, int, VectorOfInt)

Create and allocate storage for two dimensional single or multi channel dataset.

public void DsCreate(int rows, int cols, DepthType depthType, int channels, string dsLabel, int compressLevel = -1, VectorOfInt dimsChunks = null)

Parameters

rows int

Declare amount of rows

cols int

Declare amount of columns

depthType DepthType

The pixel depth type

channels int

The number of channels

dsLabel string

Specify the hdf5 dataset label. Existing dataset label will cause an error.

compressLevel int

Specify the compression level 0-9 to be used, -1 is the default value and means no compression. The value 0 also means no compression. A value 9 indicating the best compression ration. Note that a higher compression level indicates a higher computational cost. It relies on GNU gzip for compression.

dimsChunks VectorOfInt

Each array member specifies the chunking size to be used for block I/O, by default null means none at all.

DsRead(IOutputArray, string)

Read specific dataset from hdf5 file into Mat object.

public void DsRead(IOutputArray array, string dsLabel)

Parameters

array IOutputArray

Mat container where data reads will be returned.

dsLabel string

Specify the source hdf5 dataset label.

DsWrite(IInputArray, string)

Write or overwrite a Mat object into specified dataset of hdf5 file.

public void DsWrite(IInputArray array, string dsLabel)

Parameters

array IInputArray

Specify Mat data array to be written.

dsLabel string

Specify the target hdf5 dataset label.

GrCreate(string)

Create a hdf5 group with default properties. The group is closed automatically after creation.

public void GrCreate(string grLabel)

Parameters

grLabel string

Specify the hdf5 group label.

HlExist(string)

Check if label exists or not.

public bool HlExist(string label)

Parameters

label string

Specify the hdf5 dataset label.

Returns

bool

Returns true if dataset exists, and false otherwise.

KpRead(VectorOfKeyPoint, string, int, int)

Read specific keypoint dataset from hdf5 file into VectorOfKeyPoint object.

public void KpRead(VectorOfKeyPoint keypoints, string kpLabel, int offset = -1, int counts = -1)

Parameters

keypoints VectorOfKeyPoint

Container where data reads will be returned.

kpLabel string

Specify the source hdf5 dataset label.

offset int

Specify the offset location over dataset from where read starts.

counts int

Specify the amount of keypoints from dataset to read.

KpWrite(VectorOfKeyPoint, string, int, int)

Write or overwrite list of KeyPoint into specified dataset of hdf5 file.

public void KpWrite(VectorOfKeyPoint keypoints, string atLabel, int offset = -1, int counts = -1)

Parameters

keypoints VectorOfKeyPoint

Specify keypoints data list to be written.

atLabel string

Specify the target hdf5 dataset label.

offset int

Specify the offset location on dataset from where keypoints will be (over)written into dataset.

counts int

Specify the amount of keypoints that will be written into dataset.