Shapeworks Studio
2.1
Shape analysis software suite
|
This class is a data object that holds information about a Particle Shape Modeling project. More...
#include <itkPSMProject.h>
Public Types | |
typedef PSMProject | Self |
typedef Object | Superclass |
typedef SmartPointer< Self > | Pointer |
typedef SmartPointer< const Self > | ConstPointer |
Public Member Functions | |
itkNewMacro (Self) | |
itkTypeMacro (PSMProject, Object) | |
void | SetDOMNode (PSMDOMNode *p) |
PSMDOMNode::Pointer & | GetDOMNode () |
bool | HasDomains () const |
const DOMNode * | GetDomainNode (const std::string &name) const |
bool | HasDomainDistanceTransform (const std::string &name) const |
const std::vector< std::string > & | GetDomainDistanceTransform (const std::string &name) const |
bool | HasDomainCuttingPlanes (const std::string &name) const |
std::vector< vnl_vector_fixed< double, 3 > > | GetDomainCuttingPlanes (const std::string &name) const |
std::vector< std::string > | GetDomainNames () const |
const std::vector< std::string > & | GetModel (const std::string &name) |
bool | HasModel (const std::string &name) const |
const std::vector< std::string > & | GetDistanceTransforms () const |
const DOMNode * | GetOptimization () const |
unsigned int | GetNumberOfOptimizationScales () const |
bool | HasOptimizationAttribute (const std::string &name, unsigned int i=0) const |
double | GetOptimizationAttribute (const std::string &name, unsigned int i=0) const |
bool | HasProcrustes () const |
bool | HasVariables (const std::string &name) const |
std::vector< double > | GetVariables (const std::string &name) const |
const std::vector< std::string > & | GetVariablesText (const std::string &name) const |
void | Stream (std::ostream &os) |
Static Public Attributes | |
static const std::string | data_tag = "data" |
static const std::string | distance_transform_tag = "distance_transform" |
static const std::string | distance_transforms_tag = "distance_transforms" |
static const std::string | domain_tag = "domain" |
static const std::string | correspondences_tag = "correspondences" |
static const std::string | cutting_plane_tag = "cutting_plane" |
static const std::string | model_tag = "model" |
static const std::string | name_tag = "name" |
static const std::string | optimization_tag = "optimization" |
static const std::string | number_of_scales_tag = "number_of_scales" |
static const std::string | preprocessing_tag = "preprocessing" |
static const std::string | procrustes_tag = "procrustes_registration" |
static const std::string | psm_project_tag = "psm_project" |
static const std::string | scale_tag = "scale" |
static const std::string | scale_number_tag = "number" |
static const std::string | variables_tag = "variables" |
Protected Member Functions | |
void | PrintSelf (std::ostream &os, Indent indent) const |
void | StreamChildren (PSMDOMNode *, std::ostream &os, Indent indent) |
const PSMDOMNode * | GetDataNode () const |
This class is a data object that holds information about a Particle Shape Modeling project.
This class is a data object that holds information about a Particle Shape Modeling project. It contains information such as lists of input and output files, paths, processing parameters, the author of the project, and other metainformation that is useful to keep track of the multiple steps and image files necessary to compute a particle-based shape model.
At its core, this class is a wrapper around a PSMDOMNode object that provides a simplified interface to the data in the DOM node.
Definition at line 47 of file itkPSMProject.h.
typedef PSMProject itk::PSMProject::Self |
Standard class typedefs
Definition at line 51 of file itkPSMProject.h.
|
protected |
const std::vector< std::string > & itk::PSMProject::GetDistanceTransforms | ( | ) | const |
Get the file names of the distance transforms that are to be used as input to an optimization process. Corresponds to the text found in the XML tag <distance_transforms>
Definition at line 462 of file itkPSMProject.cxx.
std::vector< vnl_vector_fixed< double, 3 > > itk::PSMProject::GetDomainCuttingPlanes | ( | const std::string & | name | ) | const |
Returns a list of cutting planes for the named domain. Throws an exception if the domain does not contain cutting planes (call HasDomainCuttingPlanes first).
Definition at line 185 of file itkPSMProject.cxx.
const std::vector< std::string > & itk::PSMProject::GetDomainDistanceTransform | ( | const std::string & | name | ) | const |
Returns the name of the distance transform from the given domain
Definition at line 118 of file itkPSMProject.cxx.
std::vector< std::string > itk::PSMProject::GetDomainNames | ( | ) | const |
Returns a list of the names of all domains present in the project file. Will throw an exception if no domain names are present, so call HasDomains() first to check is the file has domains defined.
Definition at line 133 of file itkPSMProject.cxx.
const DOMNode * itk::PSMProject::GetDomainNode | ( | const std::string & | name | ) | const |
Returns the node associated with the given name
Definition at line 74 of file itkPSMProject.cxx.
|
inline |
Get the DOM Node object, which contains the XML tree of parameter data. This method is only intended for special cases in which the DOM tree needs to be modified or contains nonstandard data objects.
Definition at line 90 of file itkPSMProject.h.
const std::vector< std::string > & itk::PSMProject::GetModel | ( | const std::string & | name | ) |
The file names of the original segmentations for the project. Corresponds to the text found in the XML tag <segmentations> The file names for the correspondence points for a model, specified by name. If no name is given, this method just returns the first list of names give by a model_tag.
Definition at line 477 of file itkPSMProject.cxx.
unsigned int itk::PSMProject::GetNumberOfOptimizationScales | ( | ) | const |
|
inline |
Return the DOM node with the optimization_tag. User can query optimization parameters, for example by making calls such as: GetOptimization()->GetAttribute("my_optimization_parameter"). This method returns 0 if no optimization_tag is present in the file. User should check the return value.
Definition at line 146 of file itkPSMProject.h.
double itk::PSMProject::GetOptimizationAttribute | ( | const std::string & | name, |
unsigned int | i = 0 |
||
) | const |
Returns an attribute of the optimization_tag element as a double-precision floating point number. To work with attributes that are text or integer values, you can call GetOptimization->GetAttribute instead, which will return the attribute as text, and convert as needed. This method is a convenience for the most common case. User may optionally provide the scale, if there are multiple scales in the optimization.
Definition at line 308 of file itkPSMProject.cxx.
std::vector< double > itk::PSMProject::GetVariables | ( | const std::string & | name | ) | const |
Returns a vector of doubles for the variable_tag with the specified name. This is a convenience method for the common case. For more complex parsing, the user can call GetVariablesText(name). This method will throw an exception if the variable name does not exist, so User should first check using HasVariables.
Definition at line 405 of file itkPSMProject.cxx.
const std::vector< std::string > & itk::PSMProject::GetVariablesText | ( | const std::string & | name | ) | const |
Returns the text for the specified variable. This method will throw an exception if the variable does no exist, so User should first check HasVariables.
Definition at line 417 of file itkPSMProject.cxx.
bool itk::PSMProject::HasDomainCuttingPlanes | ( | const std::string & | name | ) | const |
Returns true if the named domain has cutting planes defined
Definition at line 165 of file itkPSMProject.cxx.
bool itk::PSMProject::HasDomainDistanceTransform | ( | const std::string & | name | ) | const |
Returns true if the named domain has distance transforms defined
Definition at line 101 of file itkPSMProject.cxx.
bool itk::PSMProject::HasDomains | ( | ) | const |
Returns true if the file has specified at least one "domain" tag.
Definition at line 56 of file itkPSMProject.cxx.
bool itk::PSMProject::HasModel | ( | const std::string & | name | ) | const |
Returns true if the model with the specified name is given.
Definition at line 505 of file itkPSMProject.cxx.
bool itk::PSMProject::HasOptimizationAttribute | ( | const std::string & | name, |
unsigned int | i = 0 |
||
) | const |
Returns true if the optimization_tag element includes the given parameter at the given scale (optional). Also returns false if no optimization_tag exists.
Definition at line 265 of file itkPSMProject.cxx.
bool itk::PSMProject::HasProcrustes | ( | ) | const |
Returns true if the project has a procrustes tag
Definition at line 360 of file itkPSMProject.cxx.
bool itk::PSMProject::HasVariables | ( | const std::string & | name | ) | const |
Returns true if the project has a variables_tag with the specified name.
Definition at line 376 of file itkPSMProject.cxx.
itk::PSMProject::itkNewMacro | ( | Self | ) |
Method for creation through the object factory.
itk::PSMProject::itkTypeMacro | ( | PSMProject | , |
Object | |||
) |
Run-time type information (and related methods).
void itk::PSMProject::SetDOMNode | ( | PSMDOMNode * | p | ) |
Set the DOM node object, which contains the XML tree of parameter data. This method will throw an exception if the DOMNode is not a valid PSMProject file.
Definition at line 42 of file itkPSMProject.cxx.
void itk::PSMProject::Stream | ( | std::ostream & | os | ) |
Stream the XML content of this project to a standard ostream. Note that this method cannot be made const because the necessary accessor methods in itkDOMNode are not defined as const. This method, however, does not modify the content of the PSMProject.
Definition at line 540 of file itkPSMProject.cxx.
|
protected |
Helper function for Stream. Like Stream, this method cannot be const due to nonconst accessor methods in itkDOMNode.
Definition at line 547 of file itkPSMProject.cxx.
|
static |
Reserved keywords for use in XML parameter files.
Definition at line 63 of file itkPSMProject.h.