Skip to content

shapeworks::ProjectUtils

Public Types

Name
using project::types::StringList StringList
using project::types::StringMap StringMap

Public Functions

Name
vtkSmartPointer< vtkTransform > convert_transform(std::vector< double > list)
convert a list of doubles from a spreadsheet to a vtkTransform
vtkSmartPointer< vtkTransform > convert_transform(std::string string)
convert a string of doubles from to a vtkTransform
std::vector< double > convert_transform(vtkSmartPointer< vtkTransform > transform)
convert a vtkTransform to a list of doubles (e.g. for project spreadsheet)
StringList determine_domain_names(StringList keys)
determine domain names from a subject's keys
void determine_domain_types(Project * project, StringMap key_map)
determine and set domain types
StringList get_input_prefixes()
return a list of the input prefixes
StringList get_groomed_prefixes()
return a list of the groomed prefixes
StringList get_original_keys(StringList domain_names, StringMap key_map)
extract original keys from key_map given an ordered list of domain names
StringList get_values(StringList prefixes, StringList domain_names, StringMap key_map)
get the values for a list of prefixes from key_map, ordered by domain_names
std::vector< std::vector< double > > get_transforms(std::string prefix, StringList domain_names, StringMap key_map)
get the transforms for a prefix from key_map, ordered by domain_names
StringMap get_value_map(std::vector< std::string > prefix, StringMap key_map)
get a map for a list of prefixes from a key_map (e.g. group_, or feature_)
StringMap get_extra_columns(StringMap key_map)
get any extra columns that don't match prefixes
DomainType determine_domain_type(std::string filename)
determine the domain type, given a filename
bool starts_with(std::string str, std::string prefix)
std::string transform_to_string(std::vector< double > transform)
std::vector< std::string > convert_domain_types(std::vector< DomainType > domain_types)
std::vector< std::string > convert_groomed_domain_types(std::vector< DomainType > domain_types)
StringMap convert_subject_to_map(Project * project, Subject * subject)

Public Types Documentation

using StringList

using shapeworks::ProjectUtils::StringList =  project::types::StringList;

using StringMap

using shapeworks::ProjectUtils::StringMap =  project::types::StringMap;

Public Functions Documentation

function convert_transform

static vtkSmartPointer< vtkTransform > convert_transform(
    std::vector< double > list
)

convert a list of doubles from a spreadsheet to a vtkTransform

function convert_transform

static vtkSmartPointer< vtkTransform > convert_transform(
    std::string string
)

convert a string of doubles from to a vtkTransform

function convert_transform

static std::vector< double > convert_transform(
    vtkSmartPointer< vtkTransform > transform
)

convert a vtkTransform to a list of doubles (e.g. for project spreadsheet)

function determine_domain_names

static StringList determine_domain_names(
    StringList keys
)

determine domain names from a subject's keys

function determine_domain_types

static void determine_domain_types(
    Project * project,
    StringMap key_map
)

determine and set domain types

function get_input_prefixes

static StringList get_input_prefixes()

return a list of the input prefixes

function get_groomed_prefixes

static StringList get_groomed_prefixes()

return a list of the groomed prefixes

function get_original_keys

static StringList get_original_keys(
    StringList domain_names,
    StringMap key_map
)

extract original keys from key_map given an ordered list of domain names

function get_values

static StringList get_values(
    StringList prefixes,
    StringList domain_names,
    StringMap key_map
)

get the values for a list of prefixes from key_map, ordered by domain_names

function get_transforms

static std::vector< std::vector< double > > get_transforms(
    std::string prefix,
    StringList domain_names,
    StringMap key_map
)

get the transforms for a prefix from key_map, ordered by domain_names

function get_value_map

static StringMap get_value_map(
    std::vector< std::string > prefix,
    StringMap key_map
)

get a map for a list of prefixes from a key_map (e.g. group_, or feature_)

function get_extra_columns

static StringMap get_extra_columns(
    StringMap key_map
)

get any extra columns that don't match prefixes

function determine_domain_type

static DomainType determine_domain_type(
    std::string filename
)

determine the domain type, given a filename

function starts_with

static bool starts_with(
    std::string str,
    std::string prefix
)

function transform_to_string

static std::string transform_to_string(
    std::vector< double > transform
)

function convert_domain_types

static std::vector< std::string > convert_domain_types(
    std::vector< DomainType > domain_types
)

function convert_groomed_domain_types

static std::vector< std::string > convert_groomed_domain_types(
    std::vector< DomainType > domain_types
)

function convert_subject_to_map

static StringMap convert_subject_to_map(
    Project * project,
    Subject * subject
)

Updated on 2024-03-17 at 12:58:44 -0600