pyEMsoftToolsLib¶
This page contains all the wrappped types and subroutines
-
pyEMsoftTools.EMEBSDGlobalOptimizationUpdate(string, Opt, EBSD, Pattern)¶ loadOptimizationData(string, Opt, EBSD, Pattern)
Update the template file for global optimization
Parameters: - string (str) –
- Opt (class) –
- EBSD (class) –
- Pattern (class) –
-
pyEMsoftTools.EMEBSDnamelistUpdate(EBSD)¶ Update EMEBSD nml file with EBSD namelist class
Parameters: EBSD (class) –
-
pyEMsoftTools.EMsoftPCtoPC(str, enl)¶ enl = EMsoftPCtoPC(str, PC, enl)
Convert EMsoft pattern center to vendor’s convention
Parameters: - str (str) –
- PC (class) –
- enl (class) –
Returns: enl
Return type: class
-
class
pyEMsoftTools.ExtractData(master)¶ Module ExtractData
Extract hdf5 data from crystal structure file or master EBSD file
-
crystal_data()¶ Crystal, AtomDict, Info = crystal_data()
Extract everything about the crystal structure information
Returns: - Crystal (dict)
- AtomDict (dict)
- Info (dict)
-
ebsd_master()¶ master_info, master_pattern = ebsd_master()
Extract 2D master patterns (stereographic projection and Lambert projection) as well as related information
Returns: - master_info (dict)
- master_pattern (float array)
-
-
pyEMsoftTools.PCtoEMsoftPC(str, PC, enl)¶ enl = PCtoEMsoftPC(str, PC, enl)
Convert pattern center to EMsoft convention
Parameters: - str (str) –
- PC (class) –
- enl (class) –
Returns: enl
Return type: class
-
class
pyEMsoftTools.Tools¶ Module Tools
Some tools to help with pyEMsoft module
-
static
get_character_array(ASCII_array)¶ CArray = get_character_array(ASCII_array)
Convert numpy array (ASCII) data into character array
Parameters: ASCII_array (float array) – Returns: CArray Return type: character array
-
static
get_crystal_system_name(crystal_system_number)¶ crystal_system_name = get_crystal_system_name(crystal_system_number)
Get the corresponding name of the crystal system
Parameters: crystal_system_number (int) – Returns: crystal_system_name Return type: str
-
static
get_point_group(SGNUM)¶ pgnum = get_point_group(SGNUM)
Determine the point group a space group number
Parameters: SGNUM (int) – Returns: pgnum Return type: int
-
static
get_space_string(chr)¶ transspace_str=get_space_string(chr)
Get the corresponding name of the space in strings
Parameters: chr (str) – Returns: transspace_str Return type: str
-
static
-
pyEMsoftTools.circular_mask(ht, wd)¶ mask = circular_mask(ht, wd)
Create a circular mask for a pattern
Parameters: binned (array) – Returns: mask Return type: int array
-
pyEMsoftTools.createAngleFile(emdatapath, angle_type, Pattern, AnglesMatrix)¶ Create Euler angle file for EMEBSD program
Parameters: - emdatapath (str) –
- angle_type (str) –
- Pattern (class) –
- AnglesMatrix (float array) –
-
pyEMsoftTools.getGrayscale(binned)¶ bpatint = getGrayscale(binned)
Get grayscale pattern [0,255]
Parameters: binned (array) – Returns: bpatint Return type: int array
-
pyEMsoftTools.getSingleEBSDPattern(str, EBSD, Pattern, path)¶ TargetPattern = getSingleEBSDPattern(str, EBSD, Pattern, path)
Get a single EBSD pattern from a pattern file
Parameters: - str (str) –
- EBSD (class) –
- Pattern (class) –
- path (str) –
Returns: TargetPattern
Return type: array
-
pyEMsoftTools.loadBrukerHDF(str, path)¶ enl, patterndata, angles = loadBrukerHDF(str, path)
Load metadata from BrukerHDF pattern file
Parameters: - str (str) –
- path (str) –
Returns: - enl (class)
- patterndata (class)
- angles (float array)
-
pyEMsoftTools.loadBrukerHDFSEM(str, path)¶ PatternQuality, SEM= loadBrukerHDFSEM(str, path)
Load pattern quality map and SEM array from BrukerHDF file
Parameters: - str (str) –
- path (str) –
Returns: - PatternQuality (float array)
- SEM (nt array)
-
pyEMsoftTools.loadOptimizationData(emdatapath, inputtype, EBSD, Opt)¶ EBSD_Opt, quaternion =loadOptimizationData(emdatapath, inputtype, EBSD)
Load global optimization output data with default output file name
Parameters: - emdatapath (str) –
- inputtype (str) –
- EBSD (class) –
- Opt (class) –
Returns: - EBSD_Opt (class)
- quaternion (float array)
- Ftensor (float array)
-
pyEMsoftTools.loadPattern(inputtype, data, path)¶ enl, patterndata, angles = loadPattern(inputtype, data, path)
Load metadata from pattern file
Parameters: - inputtype (str) –
- data (class) –
- path (str) –
Returns: - enl (class)
- patterndata (class)
- angles (float array)
-
pyEMsoftTools.loadSEM(inputtype, data, path)¶ PatternQuality, SEM = loadSEM(inputtype, data, path)
Load pattern quality map and SEM array from pattern file
Parameters: - inputtype (str) –
- data (class) –
- path (str) –
Returns: - PatternQuality (float array)
- SEM (nt array)
-
pyEMsoftTools.loadTSLHDF(str, path)¶ enl, patterndata, angles = loadBrukerHDF(str, path)
Load metadata from TSLHDF pattern file
Parameters: - str (str) –
- path (str) –
Returns: - enl (class)
- patterndata (class)
- angles (float array)
-
pyEMsoftTools.loadTSLHDFSEM(str, path)¶ PatternQuality, SEM= loadTSLHDFSEM(str, path)
Load pattern quality map and SEM array from TSLHDF file
Parameters: - str (str) –
- path (str) –
Returns: - PatternQuality (float array)
- SEM (nt array)