exportEBSD_h5 edit page

export EBSD data to an HDF5 file

Description

There is no such thing as "the" EBSD HDF5 format - every vendor nests its data differently and stores far more than MTEX imports, from the raw patterns to the acquisition settings. Writing one from scratch therefore loses everything MTEX does not model. This function instead takes the file the data was imported from as a reference, copies it, and writes the changed data into the copy, so the result is still a file of the vendor's own format that its software reads.

The reference file is the one the data came from - EBSD.load remembers it in ebsd.opt.h5 together with the data sets it read - or one named explicitly. Only measurements that are still there are written, and only into the data sets the import resolved, so anything else in the file is passed through untouched.

A reference file is therefore required. MTEX used to write a flat layout of its own when there was none, but nothing could read it back - not MTEX and no vendor tool - so it was removed. To carry a map between MTEX sessions use a .mat file, which keeps everything this one dropped.

Syntax

% round trip - the reference is the file the data came from
ebsd = EBSD.load('myfile.h5oina')
ebsd = ebsd.denoise(halfQuadraticFilter)
export(ebsd,'denoised.h5oina')
% name the reference explicitly
exportEBSD_h5(ebsd,'denoised.h5oina','reference','myfile.h5oina')

Input

ebsd EBSD
fName file name of the file to be written

Options

reference file to copy and write the changed data into

Flags

noProp write orientations and phases only, leave properties alone

See also

EBSD.load exportEBSD_ctf exportEBSD_ang