shapeworks::Sampler
Public Classes
Name | |
---|---|
struct | CuttingPlaneType |
struct | FFCType |
struct | SphereType |
Public Types
Name | |
---|---|
using float | PixelType |
using itk::Image< PixelType, Dimension > | ImageType |
using ImageType::PointType | PointType |
using itk::ParticleMeanCurvatureAttribute< PixelType, Dimension > | MeanCurvatureCacheType |
using vnl_matrix_fixed< double, Dimension+1, Dimension+1 > | TransformType |
using itk::ParticleGradientDescentPositionOptimizer< PixelType, Dimension > | OptimizerType |
Public Functions
Name | |
---|---|
itkGetObjectMacro(ParticleSystem , itk::ParticleSystem ) | |
itkGetConstObjectMacro(ParticleSystem , itk::ParticleSystem ) | |
Sampler() Constructor. |
|
virtual | ~Sampler() Destructor. |
itk::ParticleEntropyGradientFunction< ImageType::PixelType, Dimension > * | GetGradientFunction() |
itk::ParticleCurvatureEntropyGradientFunction< ImageType::PixelType, Dimension > * | GetCurvatureGradientFunction() |
itk::ParticleModifiedCotangentEntropyGradientFunction< ImageType::PixelType, Dimension > * | GetModifiedCotangentGradientFunction() |
itk::ParticleConstrainedModifiedCotangentEntropyGradientFunction< ImageType::PixelType, Dimension > * | GetConstrainedModifiedCotangentGradientFunction() |
itk::ParticleOmegaGradientFunction< ImageType::PixelType, Dimension > * | GetOmegaGradientFunction() |
itkGetObjectMacro(Optimizer , OptimizerType ) | |
itkGetConstObjectMacro(Optimizer , OptimizerType ) | |
void | SetPointsFile(unsigned int i, const std::string & s) |
void | SetPointsFile(const std::string & s) |
void | SetMeshFile(unsigned int i, const std::string & s) |
void | SetMeshFile(const std::string & s) |
void | SetMeshFiles(const std::vector< std::string > & s) |
void | AddImage(ImageType::Pointer image, double narrow_band, std::string name ="") |
void | ApplyConstraintsToZeroCrossing() |
void | AddMesh(std::shared_ptr< shapeworks::MeshWrapper > mesh) |
void | AddContour(vtkSmartPointer< vtkPolyData > poly_data) |
void | SetFidsFiles(const std::vector< std::string > & s) |
void | SetFeaFiles(const std::vector< std::string > & s) |
void | SetFeaGradFiles(const std::vector< std::string > & s) |
void | SetDomainsPerShape(int n) |
void | SetCuttingPlane(unsigned int i, const vnl_vector_fixed< double, Dimension > & va, const vnl_vector_fixed< double, Dimension > & vb, const vnl_vector_fixed< double, Dimension > & vc) |
void | AddFreeFormConstraint(unsigned int i, const std::vector< std::vector< Eigen::Vector3d > > boundaries, const Eigen::Vector3d query) |
void | TransformCuttingPlanes(unsigned int i) |
void | AddSphere(unsigned int i, vnl_vector_fixed< double, Dimension > & c, double r) |
virtual void | SetAdaptivityMode(int mode) |
int | GetAdaptivityMode() const |
void | SetCorrespondenceOn() |
void | SetCorrespondenceOff() |
void | SetSamplingOn() |
void | SetSamplingOff() |
bool | GetCorrespondenceOn() const |
bool | GetSamplingOn() const |
virtual void | SetCorrespondenceMode(shapeworks::CorrespondenceMode mode) |
void | RegisterGeneralShapeMatrices() |
void | SetAttributeScales(const std::vector< double > & s) |
void | SetXYZ(unsigned int i, bool flag) |
void | SetNormals(int i, bool flag) |
void | SetAttributesPerDomain(const std::vector< int > s) |
itk::ParticleShapeMatrixAttribute< double, Dimension > * | GetShapeMatrix() |
itk::ParticleGeneralShapeMatrix< double, Dimension > * | GetGeneralShapeMatrix() |
itk::ParticleGeneralShapeGradientMatrix< double, Dimension > * | GetGeneralShapeGradientMatrix() |
itk::ParticleDualVectorFunction< Dimension > * | GetLinkingFunction() |
itk::ParticleEnsembleEntropyFunction< Dimension > * | GetEnsembleEntropyFunction() |
itk::ParticleEnsembleEntropyFunction< Dimension > * | GetEnsembleRegressionEntropyFunction() |
itk::ParticleEnsembleEntropyFunction< Dimension > * | GetEnsembleMixedEffectsEntropyFunction() |
itk::ParticleMeshBasedGeneralEntropyGradientFunction< Dimension > * | GetMeshBasedGeneralEntropyGradientFunction() |
const itk::ParticleDualVectorFunction< Dimension > * | GetLinkingFunction() const |
const itk::ParticleEnsembleEntropyFunction< Dimension > * | GetEnsembleEntropyFunction() const |
const itk::ParticleEnsembleEntropyFunction< Dimension > * | GetEnsembleRegressionEntropyFunction() const |
const itk::ParticleEnsembleEntropyFunction< Dimension > * | GetEnsembleMixedEffectsEntropyFunction() const |
const itk::ParticleMeshBasedGeneralEntropyGradientFunction< Dimension > * | GetMeshBasedGeneralEntropyGradientFunction() const |
void | SetTimeptsPerIndividual(int n) |
shapeworks::CorrespondenceMode | GetCorrespondenceMode() const |
void | SetTransformFile(const std::string & s) |
void | SetTransformFile(const char * s) |
void | SetPrefixTransformFile(const std::string & s) |
void | SetPrefixTransformFile(const char * s) |
void | SetPairwisePotentialType(int pairwise_potential_type) |
int | GetPairwisePotentialType() |
void | SetVerbosity(unsigned int val) |
unsigned int | GetVerbosity() |
MeanCurvatureCacheType * | GetMeanCurvatureCache() |
void | SetSharedBoundaryEnabled(bool enabled) |
void | SetSharedBoundaryWeight(double weight) |
void | ReadTransforms() |
void | ReadPointsFiles() |
virtual void | AllocateDataCaches() |
virtual void | AllocateDomainsAndNeighborhoods() |
virtual void | InitializeOptimizationFunctions() |
virtual void | Initialize() |
virtual void | ReInitialize() |
virtual void | Execute() |
std::vector< std::vector< std::pair< Eigen::Vector3d, Eigen::Vector3d > > > | ComputeCuttingPlanes() |
Eigen::Vector3d | ComputePlaneNormal(const vnl_vector< double > & a, const vnl_vector< double > & b, const vnl_vector< double > & c) |
std::vector< FFCType > | GetFFCs() |
void | SetMeshFFCMode(bool mesh_ffc_mode) |
Protected Functions
Name | |
---|---|
void | GenerateData() |
bool | GetInitialized() |
void | SetInitialized(bool value) |
bool | GetInitializing() |
void | SetInitializing(bool value) |
bool | initialize_ffcs(size_t dom) |
Public Attributes
Name | |
---|---|
constexpr unsigned int | Dimension |
Protected Attributes
Public Types Documentation
using PixelType
using shapeworks::Sampler::PixelType = float;
using ImageType
using shapeworks::Sampler::ImageType = itk::Image<PixelType, Dimension>;
using PointType
using shapeworks::Sampler::PointType = ImageType::PointType;
using MeanCurvatureCacheType
using shapeworks::Sampler::MeanCurvatureCacheType = itk::ParticleMeanCurvatureAttribute<PixelType, Dimension>;
using TransformType
using shapeworks::Sampler::TransformType = vnl_matrix_fixed<double, Dimension + 1, Dimension + 1>;
using OptimizerType
using shapeworks::Sampler::OptimizerType = itk::ParticleGradientDescentPositionOptimizer<PixelType, Dimension>;
Public Functions Documentation
function itkGetObjectMacro
itkGetObjectMacro(
ParticleSystem ,
itk::ParticleSystem
)
Returns the particle system used in the surface sampling.
function itkGetConstObjectMacro
itkGetConstObjectMacro(
ParticleSystem ,
itk::ParticleSystem
)
function Sampler
Sampler()
Constructor.
function ~Sampler
inline virtual ~Sampler()
Destructor.
function GetGradientFunction
inline itk::ParticleEntropyGradientFunction< ImageType::PixelType, Dimension > * GetGradientFunction()
Returns a pointer to the gradient function used.
function GetCurvatureGradientFunction
inline itk::ParticleCurvatureEntropyGradientFunction< ImageType::PixelType, Dimension > * GetCurvatureGradientFunction()
function GetModifiedCotangentGradientFunction
inline itk::ParticleModifiedCotangentEntropyGradientFunction< ImageType::PixelType, Dimension > * GetModifiedCotangentGradientFunction()
function GetConstrainedModifiedCotangentGradientFunction
inline itk::ParticleConstrainedModifiedCotangentEntropyGradientFunction< ImageType::PixelType, Dimension > * GetConstrainedModifiedCotangentGradientFunction()
function GetOmegaGradientFunction
inline itk::ParticleOmegaGradientFunction< ImageType::PixelType, Dimension > * GetOmegaGradientFunction()
function itkGetObjectMacro
itkGetObjectMacro(
Optimizer ,
OptimizerType
)
Return a pointer to the optimizer object.
function itkGetConstObjectMacro
itkGetConstObjectMacro(
Optimizer ,
OptimizerType
)
function SetPointsFile
inline void SetPointsFile(
unsigned int i,
const std::string & s
)
Optionally provide a filename for an initial point set.
function SetPointsFile
inline void SetPointsFile(
const std::string & s
)
function SetMeshFile
inline void SetMeshFile(
unsigned int i,
const std::string & s
)
Optionally provide a filename for a mesh with geodesic distances.
function SetMeshFile
inline void SetMeshFile(
const std::string & s
)
function SetMeshFiles
inline void SetMeshFiles(
const std::vector< std::string > & s
)
function AddImage
void AddImage(
ImageType::Pointer image,
double narrow_band,
std::string name =""
)
function ApplyConstraintsToZeroCrossing
inline void ApplyConstraintsToZeroCrossing()
function AddMesh
void AddMesh(
std::shared_ptr< shapeworks::MeshWrapper > mesh
)
function AddContour
void AddContour(
vtkSmartPointer< vtkPolyData > poly_data
)
function SetFidsFiles
inline void SetFidsFiles(
const std::vector< std::string > & s
)
function SetFeaFiles
inline void SetFeaFiles(
const std::vector< std::string > & s
)
function SetFeaGradFiles
inline void SetFeaGradFiles(
const std::vector< std::string > & s
)
function SetDomainsPerShape
inline void SetDomainsPerShape(
int n
)
function SetCuttingPlane
void SetCuttingPlane(
unsigned int i,
const vnl_vector_fixed< double, Dimension > & va,
const vnl_vector_fixed< double, Dimension > & vb,
const vnl_vector_fixed< double, Dimension > & vc
)
Optionally supply a cutting plane that will be set as a particle optimization constraint in the image domains.
function AddFreeFormConstraint
void AddFreeFormConstraint(
unsigned int i,
const std::vector< std::vector< Eigen::Vector3d > > boundaries,
const Eigen::Vector3d query
)
function TransformCuttingPlanes
void TransformCuttingPlanes(
unsigned int i
)
Transform a cutting plane based on procrustes transformation
function AddSphere
void AddSphere(
unsigned int i,
vnl_vector_fixed< double, Dimension > & c,
double r
)
Optionally add spheres that may be used as constraints to the domain.
function SetAdaptivityMode
inline virtual void SetAdaptivityMode(
int mode
)
This method sets the optimization function for the sampling. mode 0 = isotropic adaptivity mode 1 = no adaptivity
function GetAdaptivityMode
inline int GetAdaptivityMode() const
function SetCorrespondenceOn
inline void SetCorrespondenceOn()
function SetCorrespondenceOff
inline void SetCorrespondenceOff()
function SetSamplingOn
inline void SetSamplingOn()
function SetSamplingOff
inline void SetSamplingOff()
function GetCorrespondenceOn
inline bool GetCorrespondenceOn() const
function GetSamplingOn
inline bool GetSamplingOn() const
function SetCorrespondenceMode
inline virtual void SetCorrespondenceMode(
shapeworks::CorrespondenceMode mode
)
This method sets the optimization function for correspondences between surfaces (domains).
function RegisterGeneralShapeMatrices
inline void RegisterGeneralShapeMatrices()
function SetAttributeScales
inline void SetAttributeScales(
const std::vector< double > & s
)
function SetXYZ
inline void SetXYZ(
unsigned int i,
bool flag
)
function SetNormals
inline void SetNormals(
int i,
bool flag
)
function SetAttributesPerDomain
inline void SetAttributesPerDomain(
const std::vector< int > s
)
function GetShapeMatrix
inline itk::ParticleShapeMatrixAttribute< double, Dimension > * GetShapeMatrix()
function GetGeneralShapeMatrix
inline itk::ParticleGeneralShapeMatrix< double, Dimension > * GetGeneralShapeMatrix()
function GetGeneralShapeGradientMatrix
inline itk::ParticleGeneralShapeGradientMatrix< double, Dimension > * GetGeneralShapeGradientMatrix()
function GetLinkingFunction
inline itk::ParticleDualVectorFunction< Dimension > * GetLinkingFunction()
function GetEnsembleEntropyFunction
inline itk::ParticleEnsembleEntropyFunction< Dimension > * GetEnsembleEntropyFunction()
function GetEnsembleRegressionEntropyFunction
inline itk::ParticleEnsembleEntropyFunction< Dimension > * GetEnsembleRegressionEntropyFunction()
function GetEnsembleMixedEffectsEntropyFunction
inline itk::ParticleEnsembleEntropyFunction< Dimension > * GetEnsembleMixedEffectsEntropyFunction()
function GetMeshBasedGeneralEntropyGradientFunction
inline itk::ParticleMeshBasedGeneralEntropyGradientFunction< Dimension > * GetMeshBasedGeneralEntropyGradientFunction()
function GetLinkingFunction
inline const itk::ParticleDualVectorFunction< Dimension > * GetLinkingFunction() const
function GetEnsembleEntropyFunction
inline const itk::ParticleEnsembleEntropyFunction< Dimension > * GetEnsembleEntropyFunction() const
function GetEnsembleRegressionEntropyFunction
inline const itk::ParticleEnsembleEntropyFunction< Dimension > * GetEnsembleRegressionEntropyFunction() const
function GetEnsembleMixedEffectsEntropyFunction
inline const itk::ParticleEnsembleEntropyFunction< Dimension > * GetEnsembleMixedEffectsEntropyFunction() const
function GetMeshBasedGeneralEntropyGradientFunction
inline const itk::ParticleMeshBasedGeneralEntropyGradientFunction< Dimension > * GetMeshBasedGeneralEntropyGradientFunction() const
function SetTimeptsPerIndividual
inline void SetTimeptsPerIndividual(
int n
)
function GetCorrespondenceMode
inline shapeworks::CorrespondenceMode GetCorrespondenceMode() const
function SetTransformFile
inline void SetTransformFile(
const std::string & s
)
function SetTransformFile
inline void SetTransformFile(
const char * s
)
function SetPrefixTransformFile
inline void SetPrefixTransformFile(
const std::string & s
)
function SetPrefixTransformFile
inline void SetPrefixTransformFile(
const char * s
)
function SetPairwisePotentialType
inline void SetPairwisePotentialType(
int pairwise_potential_type
)
function GetPairwisePotentialType
inline int GetPairwisePotentialType()
function SetVerbosity
inline void SetVerbosity(
unsigned int val
)
function GetVerbosity
inline unsigned int GetVerbosity()
function GetMeanCurvatureCache
inline MeanCurvatureCacheType * GetMeanCurvatureCache()
function SetSharedBoundaryEnabled
inline void SetSharedBoundaryEnabled(
bool enabled
)
function SetSharedBoundaryWeight
inline void SetSharedBoundaryWeight(
double weight
)
function ReadTransforms
void ReadTransforms()
function ReadPointsFiles
void ReadPointsFiles()
function AllocateDataCaches
virtual void AllocateDataCaches()
function AllocateDomainsAndNeighborhoods
virtual void AllocateDomainsAndNeighborhoods()
function InitializeOptimizationFunctions
virtual void InitializeOptimizationFunctions()
function Initialize
inline virtual void Initialize()
function ReInitialize
virtual void ReInitialize()
function Execute
virtual void Execute()
function ComputeCuttingPlanes
inline std::vector< std::vector< std::pair< Eigen::Vector3d, Eigen::Vector3d > > > ComputeCuttingPlanes()
function ComputePlaneNormal
inline Eigen::Vector3d ComputePlaneNormal(
const vnl_vector< double > & a,
const vnl_vector< double > & b,
const vnl_vector< double > & c
)
function GetFFCs
inline std::vector< FFCType > GetFFCs()
function SetMeshFFCMode
inline void SetMeshFFCMode(
bool mesh_ffc_mode
)
Protected Functions Documentation
function GenerateData
void GenerateData()
function GetInitialized
inline bool GetInitialized()
function SetInitialized
inline void SetInitialized(
bool value
)
function GetInitializing
inline bool GetInitializing()
function SetInitializing
inline void SetInitializing(
bool value
)
function initialize_ffcs
bool initialize_ffcs(
size_t dom
)
Public Attributes Documentation
variable Dimension
static constexpr unsigned int Dimension = 3;
Protected Attributes Documentation
variable m_Initialized
bool m_Initialized {false};
variable m_AdaptivityMode
int m_AdaptivityMode {0};
variable m_Initializing
bool m_Initializing {false};
variable m_Optimizer
OptimizerType::Pointer m_Optimizer;
variable m_GradientFunction
itk::ParticleEntropyGradientFunction< ImageType::PixelType, Dimension >::Pointer m_GradientFunction;
variable m_CurvatureGradientFunction
itk::ParticleCurvatureEntropyGradientFunction< ImageType::PixelType, Dimension >::Pointer m_CurvatureGradientFunction;
variable m_ModifiedCotangentGradientFunction
itk::ParticleModifiedCotangentEntropyGradientFunction< ImageType::PixelType, Dimension >::Pointer m_ModifiedCotangentGradientFunction;
variable m_ConstrainedModifiedCotangentGradientFunction
itk::ParticleConstrainedModifiedCotangentEntropyGradientFunction< ImageType::PixelType, Dimension >::Pointer m_ConstrainedModifiedCotangentGradientFunction;
variable m_OmegaGradientFunction
itk::ParticleOmegaGradientFunction< ImageType::PixelType, Dimension >::Pointer m_OmegaGradientFunction;
variable m_Sigma1Cache
itk::ParticleContainerArrayAttribute< double, Dimension >::Pointer m_Sigma1Cache;
variable m_Sigma2Cache
itk::ParticleContainerArrayAttribute< double, Dimension >::Pointer m_Sigma2Cache;
variable m_MeanCurvatureCache
MeanCurvatureCacheType::Pointer m_MeanCurvatureCache;
variable m_ParticleSystem
itk::ParticleSystem::Pointer m_ParticleSystem;
variable m_DomainList
std::vector< ParticleDomain::Pointer > m_DomainList;
variable m_NeighborhoodList
std::vector< itk::ParticleSurfaceNeighborhood< ImageType >::Pointer > m_NeighborhoodList;
variable m_pairwise_potential_type
int m_pairwise_potential_type;
variable m_CorrespondenceMode
shapeworks::CorrespondenceMode m_CorrespondenceMode;
variable m_LinkingFunction
itk::ParticleDualVectorFunction< Dimension >::Pointer m_LinkingFunction;
variable m_EnsembleEntropyFunction
itk::ParticleEnsembleEntropyFunction< Dimension >::Pointer m_EnsembleEntropyFunction;
variable m_EnsembleRegressionEntropyFunction
itk::ParticleEnsembleEntropyFunction< Dimension >::Pointer m_EnsembleRegressionEntropyFunction;
variable m_EnsembleMixedEffectsEntropyFunction
itk::ParticleEnsembleEntropyFunction< Dimension >::Pointer m_EnsembleMixedEffectsEntropyFunction;
variable m_ShapeMatrix
itk::ParticleShapeMatrixAttribute< double, Dimension >::Pointer m_ShapeMatrix;
variable m_LinearRegressionShapeMatrix
itk::ParticleShapeLinearRegressionMatrixAttribute< double, Dimension >::Pointer m_LinearRegressionShapeMatrix;
variable m_MixedEffectsShapeMatrix
itk::ParticleShapeMixedEffectsMatrixAttribute< double, Dimension >::Pointer m_MixedEffectsShapeMatrix;
variable m_GeneralShapeMatrix
itk::ParticleGeneralShapeMatrix< double, Dimension >::Pointer m_GeneralShapeMatrix;
variable m_GeneralShapeGradMatrix
itk::ParticleGeneralShapeGradientMatrix< double, Dimension >::Pointer m_GeneralShapeGradMatrix;
variable m_MeshBasedGeneralEntropyGradientFunction
itk::ParticleMeshBasedGeneralEntropyGradientFunction< Dimension >::Pointer m_MeshBasedGeneralEntropyGradientFunction;
Updated on 2022-07-23 at 16:40:06 -0600