defdap.file_readers module¶
-
class
defdap.file_readers.
EBSDDataLoader
[source]¶ Bases:
object
Class containing methods for loading and checking EBSD data
-
class
defdap.file_readers.
EdaxAngLoader
[source]¶
-
class
defdap.file_readers.
OxfordBinaryLoader
[source]¶
-
class
defdap.file_readers.
DICDataLoader
[source]¶ Bases:
object
Class containing methods for loading and checking HRDIC data
-
checkData
()[source]¶ Calculate size of map from loaded data and check it matches values from metadata.
- Return type:
-
-
defdap.file_readers.
readUntilString
(file, termString, commentChar='*', lineProcess=None, exact=False)[source]¶ Read lines in a file until a line starting with the termString is encountered. The file position is returned before the line starting with the termString when found. Comment and empty lines are ignored.
- Parameters:
file (
TextIO
) – An open python text file object.termString (
str
) – String to terminate reading.commentChar (
str
) – Character at start of a comment line to ignore.lineProcess (
Optional
[Callable
[[str
],Any
]]) – Function to apply to each line when loaded.exact (
bool
) – A line must exactly match termString to stop.
- Returns:
List of processed lines loaded from file.
- Return type: