file_reader#
- kikuchipy.io.plugins.nordif.file_reader(filename: str | Path, mmap_mode: str | None = None, scan_size: int | tuple[int, ...] | None = None, pattern_size: tuple[int, ...] | None = None, setting_file: str | None = None, lazy: bool = False) list[dict] [source]#
Read electron backscatter patterns from a NORDIF data file.
Not meant to be used directly; use
load()
instead.- Parameters:
- filename
File path to NORDIF data file.
- mmap_mode
Memory map mode. If not given, “r” is used unless lazy is True, in which case “c” is used.
- scan_size
Scan size in number of patterns in width and height.
- pattern_size
Pattern size in detector pixels in width and height.
- setting_file
File path to NORDIF setting file (default is “Setting.txt” in same directory as filename).
- lazy
Open the data lazily without actually reading the data from disk until required. Allows opening arbitrary sized datasets. Default is False.
- Returns:
scan
Data, axes, metadata and original metadata.