libatomprobe
Library for Atom Probe Tomography (APT) computation
Classes | Namespaces | Typedefs | Enumerations | Functions | Variables
dataFiles.h File Reference
#include <vector>
#include <atomic>
#include <inttypes.h>
#include "atomprobe/primitives/ionHit.h"
Include dependency graph for dataFiles.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  AtomProbe::ATO_ENTRY
 
struct  AtomProbe::SINGLE_HIT
 Single 3DAP hit event. More...
 
struct  AtomProbe::VOLTAGE_DATA
 Voltage data structure – these updates occur periodically during the experiment. More...
 
struct  AtomProbe::THREEDAP_DATA
 experimental setup data More...
 
struct  AtomProbe::THREEDAP_EXPERIMENT
 Data structure that contains the experiment information present in a 3Dap file. More...
 

Namespaces

 AtomProbe
 

Typedefs

typedef struct AtomProbe::ATO_ENTRY AtomProbe::ATO_ENTRY
 

Enumerations

enum  {
  AtomProbe::RECORDREAD_ERR_GET_FILESIZE =1, AtomProbe::RECORDREAD_ERR_FILESIZE_MODULO, AtomProbe::RECORDREAD_ERR_FILE_OPEN, AtomProbe::RECORDREAD_ERR_NOMEM,
  AtomProbe::RECORDREAD_BAD_FILEREAD, AtomProbe::RECORDREAD_ERR_CHUNKOFFSET, AtomProbe::RECORDREAD_BAD_RECORD
}
 
enum  {
  AtomProbe::ATO_OPEN_FAIL =1, AtomProbe::ATO_EMPTY_FAIL, AtomProbe::ATO_SIZE_ERR, AtomProbe::ATO_VERSIONCHECK_ERR,
  AtomProbe::ATO_MEM_ERR, AtomProbe::ATO_BAD_ENDIAN_DETECT, AtomProbe::ATO_ENUM_END
}
 
enum  { AtomProbe::TEXT_ERR_FILE_OPEN =1, AtomProbe::TEXT_ERR_FILE_NUM_FIELDS, AtomProbe::TEXT_ERR_FILE_FORMAT }
 
enum  {
  AtomProbe::OPSREADER_FORMAT_CLINE_ERR =1, AtomProbe::OPSREADER_FORMAT_DETECTORLINE_ERR, AtomProbe::OPSREADER_FORMAT_LINE_DASH_ERR, AtomProbe::OPSREADER_FORMAT_LINE_VOLTAGE_ERR,
  AtomProbe::OPSREADER_FORMAT_LINE_VOLTAGE_NOBETA, AtomProbe::OPSREADER_FORMAT_LINE_VOLTAGE_DATA_ERR, AtomProbe::OPSREADER_FORMAT_LINE_VOLTAGE_DATACOUNT_ERR, AtomProbe::OPSREADER_FORMAT_LINETYPE_ERR,
  AtomProbe::OPSREADER_FORMAT_CHANNELS_ERR, AtomProbe::OPSREADER_CHANNELS_DATA_ERR, AtomProbe::OPSREADER_FORMAT_SLINE_EVENTCOUNT_ERR, AtomProbe::OPSREADER_FORMAT_SLINE_EVENTDATA_ERR,
  AtomProbe::OPSREADER_FORMAT_SLINE_FORMAT_ERR, AtomProbe::OPSREADER_FORMAT_SLINE_PREFIX_ERR, AtomProbe::OPSREADER_FORMAT_DUPLICATE_SYSDATA, AtomProbe::OPSREADER_FORMAT_DUPLICATE_DETECTORSIZE,
  AtomProbe::OPSREADER_FORMAT_TRAILING_DASH_ERR, AtomProbe::OPSREADER_FORMAT_DOUBLEDASH, AtomProbe::OPSREADER_OPEN_ERR, AtomProbe::OPSREADER_READ_ERR,
  AtomProbe::OPSREADER_ABORT_ERR, AtomProbe::OPSREADER_ENUM_END
}
 Error codes for OPS file loading. More...
 

Functions

const char * AtomProbe::getRecordReadErrString (unsigned int errCode)
 
const char * AtomProbe::getAtoErrString (unsigned int errCode)
 
unsigned int AtomProbe::loadPosFile (std::vector< IonHit > &posIons, const char *posFile)
 Load a pos file directly into a single ion list. More...
 
unsigned int AtomProbe::loadPosFile (std::vector< IonHit > &posIons, const char *posFile, unsigned int nSamplesMax)
 As per loadPosFile, but with an additional setting for the maximum number of ions to load. More...
 
const char * AtomProbe::getPosFileErrString (unsigned int errMesg)
 
unsigned int AtomProbe::savePosFile (const std::vector< Point3D > &points, float mass, const char *name, bool append=false)
 Save a vector of Point3Ds into a pos file, using a fixed mass, return nonzero on error. More...
 
unsigned int AtomProbe::savePosFile (const std::vector< IonHit > &data, const char *name, bool append=false)
 Save a vector of IonHits into a "pos" file, return nonzero on error. More...
 
unsigned int AtomProbe::saveTapsimBin (const std::vector< IonHit > &posIons, std::ostream &f)
 Write a tapsim file from a vector of IonHits. More...
 
unsigned int AtomProbe::saveTapsimBin (const std::vector< IonHit > &posIons, const char *filename)
 Write a tapsim file from a vector of ionHits. More...
 
size_t AtomProbe::loadEposFile (std::vector< EPOS_ENTRY > &outData, const char *filename)
 Load an entire "EPOS" File. More...
 
size_t AtomProbe::chunkLoadEposFile (std::vector< EPOS_ENTRY > &outData, const char *filename, unsigned int chunkSize, unsigned int chunkOffset, unsigned int &nEntriesLeft)
 Load an "EPOS" file, with a maximum chunk size. More...
 
unsigned int AtomProbe::loadTextData (const char *cpFilename, std::vector< std::vector< float > > &dataVec, std::vector< std::string > &headerVec, const char *delim="\", bool allowNan=true, bool allowConvFails=false, unsigned int headerCount=-1)
 Load a CSV, TSV or similar text file. Assumes "C" Locale for input (ie "." as decimal separator). More...
 
unsigned int AtomProbe::readPosapOps (const char *file, THREEDAP_EXPERIMENT &data, unsigned int &badLine, unsigned int &progress, std::atomic< bool > &wantAbort, unsigned int nDelayLines=2, bool strictMode=false)
 Function to read POSAP "OPS" files. More...
 
unsigned int AtomProbe::loadATOFile (const char *fileName, std::vector< ATO_ENTRY > &ions, unsigned int forceEndian=0)
 Load a LAWATAP "ATO" file. More...
 

Variables

const char * AtomProbe::RECORDREAD_ERR_STRINGS []
 
const char * AtomProbe::ATO_ERR_STRINGS []
 Human readable error messages for use with ATO reader return values. More...
 
const char * AtomProbe::OPS_ENUM_ERRSTRINGS []