SciFiReaders.readers.microscopy.spm.afm.pifm.PiFMReader#

class SciFiReaders.readers.microscopy.spm.afm.pifm.PiFMReader(file_path, *args, **kwargs)[source]#

Bases: Reader

Class that reads images, spectrograms, point spectra and associated ancillary data sets from an Anfatec scan structure.

Parameters:

file_path (str) – Path to the file that needs to be read

self._input_file_path#

Path to the file that will be read

Type:

str

Notes

  • This method will check to make sure that the provided file_path is indeed a string and a valid file path.

  • Consider calling can_read() within __init__() for validating the provided file

Raises:

FileNotFoundError

Methods

can_read

create_h5

Writes a new HDF5 file with the translated data

get_path

writes full path, directory, and file name as attributes to class

make_datasets

make_dimensions

read

read_anfatec_params

reads the scan parameters and writes them to a dictionary

read_file_desc

reads spectrogram, image, and spectra file descriptions and stores all to dictionary where the key:value pairs are filename:[all descriptors]

read_imgs

reads images and saves to dictionary

read_spectra

reads all point spectra and saves to dictionary

read_spectrograms

reads spectrograms, associated spectral values, and saves them in two dictionaries

create_h5(append_path='', overwrite=False)[source]#

Writes a new HDF5 file with the translated data

append_pathstring (Optional)

h5_file to add these data to, must be a path to the h5_file on disk

overwritebool (optional, default=False)

If True, will overwrite an existing .h5 file of the same name

get_path()[source]#

writes full path, directory, and file name as attributes to class

read()[source]#
Parameters:
  • file_path (String / unicode) – Absolute path of the .ibw file

  • verbose (Boolean (Optional)) – Whether or not to show print statements for debugging

Returns:

sidpy.Dataset – Image layers are saved as separate Dataset objects

Return type:

List of sidpy.Dataset objects.

read_anfatec_params()[source]#

reads the scan parameters and writes them to a dictionary

read_file_desc()[source]#

reads spectrogram, image, and spectra file descriptions and stores all to dictionary where the key:value pairs are filename:[all descriptors]

read_imgs()[source]#

reads images and saves to dictionary

read_spectra()[source]#

reads all point spectra and saves to dictionary

read_spectrograms()[source]#

reads spectrograms, associated spectral values, and saves them in two dictionaries