2.5.12. prismatique.load.hrtem_image_wavefunctions

hrtem_image_wavefunctions(filename, multi_dim_slice=None, skip_validation_and_conversion=False)[source]

From a given HRTEM simulation output file that stores HRTEM image wavefunctions, load a specified subcollection of said HRTEM wavefunctions into a hyperspy signal.

See the documentation for the class prismatique.hrtem.image.Params for a discussion on HRTEM image wavefunctions, which we denote as \(\left|\psi_{t}\left(\delta_{f};\mathbf{u}_{1}, \ldots,\mathbf{u}_{N}; \boldsymbol{\delta}_{\beta}\right)\right\rangle\) throughout the documentation. See also the documentation for the class prismatique.thermal.Params for additional information and context on said patterns.

Parameters:
filenamestr

The relative or absolute path to the file containing the HRTEM image wavefunctions. Any non-temporary file generated by the function prismatique.stem.sim.run(), with originally a basename of the form "hrtem_sim_wavefunction_output_of_subset_"+str(i)+".h5" is valid, where i is a nonnegative integer. See the documentation for the class prismatique.hrtem.output.Params for a discussion on the layout and structuring of prismatique HRTEM simulation output files.

multi_dim_slicetuple (int | slice | list (int)) | None, optional

The “multidimensional slice object”, which specifies the subcollection of HRTEM image wavefunctions to load from file. We define a multi-dimensional slice object as a tuple of items which contains at most one item being a list of integers, and the remaining items being slice and/or int objects.

If multi_dim_slice is a tuple of length 3, then then multi_dim_slice[0] specifies a set of atomic configuration indices, where each atomic configuration index corresponds to a frozen phonon configuration; multi_dim_slice[1] specifies a set of defocus indices, where each defocus index corresponds to a different beam defocus; and multi_dim_slice[2] specifies a set of tilt indices, where each tilt index corresponds to a different beam tilt. In this case, the current Python function will load the HRTEM image wavefunctions of the frozen phonon configurations specified by multi_dim_slice[0], generated by electron beams operating at the defocii specified by multi_dim_slice[1], and beam tilts specified by multi_dim_slice[2]. Note that prismatique.load.defocii(filename)[multi_dim_slice[1]] yields the specified defocii; and prismatique.load.hrtem_beam_tilts(filename)[multi_dim_slice[2]] yields the specified tilts.

Otherwise, if multi_dim_slice is set to None, then all the HRTEM image wavefunctions stored in the file are loaded.

skip_validation_and_conversionbool, optional

If skip_validation_and_conversion is set to False, then validations and conversions are performed on the above parameters.

Otherwise, if skip_validation_and_conversion is set to True, no validations and conversions are performed on the above parameters. This option is desired primarily when the user wants to avoid potentially expensive validation and/or conversion operations.

Returns:
hrtem_image_wavefunction_signalhyperspy._signals.complex_signal2d.ComplexSignal2D

The subcollection of HRTEM image wavefunctions, stored in an instance of the hyperspy._signals.complex_signal2d.ComplexSignal2D class. See the documentation and/or reference guide for the :hyperspy:`hyperspy <>` package for details on how to use instances of the hyperspy._signals.complex_signal2d.ComplexSignal2D class.

navigational_to_original_indices_mapdict

A dictionary that maps the navigational indices of the hyperspy signal hrtem_image_wavefunction_signal to the original indices specified by multi_dim_slice. For example, if the original atomic configuration indices map to a set of corresponding navigational indices, then navigational_to_original_indices_map["output_layer_indices"][i] yields the atomic configuration index specified in the expression single_dim_slice=multi_dim_slice[0] if multi_dim_slice is not None else slice(None) that corresponds to the i th atomic configuration index in the nagivation index space of hrtem_image_wavefunction_signal, where i is a nonnegative integer smaller than the total number of atomic configuration indices specified in single_dim_slice.