file_reader#

kikuchipy.io.plugins.kikuchipy_h5ebsd.file_reader(filename: Union[str, Path], scan_group_names: Union[None, str, List[str]] = None, lazy: bool = False, **kwargs) List[dict][source]#

Read electron backscatter diffraction patterns, a crystal map, and an EBSD detector from a kikuchipy h5ebsd file [Jackson et al., 2014].

Not ment to be used directly; use load().

The file is closed after reading if lazy=False.

Parameters:
filename

Full file path of the HDF5 file.

scan_group_names

Name or a list of names of HDF5 top group(s) containing the scan(s) to return. If not given (default), the first scan in the file is returned.

lazy

Open the data lazily without actually reading the data from disk until required. Allows opening arbitrary sized datasets. Default is False.

**kwargs

Keyword arguments passed to h5py.File.

Returns:
scan_dict_list

List of one or more dictionaries with the keys "axes", "data", "metadata", "original_metadata", "detector", "static_background", and "xmap". This dictionary can be passed as keyword arguments to create an EBSD signal.