Developer documentation
Version 3.0.3-105-gd3941f44
MR::Fixel Namespace Reference

Namespaces

namespace  Filter
 
namespace  Legacy
 
namespace  Matrix
 

Classes

class  IndexRemapper
 
struct  LoopFixelsInVoxel
 

Typedefs

using index_type = uint32_t
 

Functions

FORCE_INLINE bool is_index_filename (const std::string &path)
 
template<class HeaderType >
FORCE_INLINE bool is_index_image (const HeaderType &in)
 
template<class HeaderType >
FORCE_INLINE void check_index_image (const HeaderType &index)
 
template<class HeaderType >
FORCE_INLINE bool is_data_file (const HeaderType &in)
 
FORCE_INLINE bool is_directions_filename (const std::string &path)
 
template<class HeaderType >
FORCE_INLINE bool is_directions_file (const HeaderType &in)
 
template<class HeaderType >
FORCE_INLINE void check_data_file (const HeaderType &in)
 
FORCE_INLINE std::string get_fixel_directory (const std::string &fixel_file)
 
template<class IndexHeaderType >
FORCE_INLINE index_type get_number_of_fixels (IndexHeaderType &index_header)
 
template<class IndexHeaderType , class DataHeaderType >
FORCE_INLINE bool fixels_match (const IndexHeaderType &index_header, const DataHeaderType &data_header)
 
FORCE_INLINE void check_fixel_size (const Header &index_h, const Header &data_h)
 
FORCE_INLINE void check_fixel_directory (const std::string &path, bool create_if_missing=false, bool check_if_empty=false)
 
FORCE_INLINE Header find_index_header (const std::string &fixel_directory_path)
 
FORCE_INLINE vector< Headerfind_data_headers (const std::string &fixel_directory_path, const Header &index_header, const bool include_directions=false)
 
FORCE_INLINE Header find_directions_header (const std::string fixel_directory_path)
 
template<class IndexHeaderType >
FORCE_INLINE Header data_header_from_index (IndexHeaderType &index)
 Generate a header for a sparse data file (Nx1x1) using an index image as a template. More...
 
template<class IndexHeaderType >
FORCE_INLINE Header directions_header_from_index (IndexHeaderType &index)
 Generate a header for a fixel directions data file (Nx3x1) using an index image as a template. More...
 
FORCE_INLINE void copy_fixel_file (const std::string &input_file_path, const std::string &output_directory)
 Copy a file from one fixel directory into another. More...
 
FORCE_INLINE void copy_index_file (const std::string &input_directory, const std::string &output_directory)
 Copy the index file from one fixel directory into another. More...
 
FORCE_INLINE void copy_directions_file (const std::string &input_directory, const std::string &output_directory)
 Copy the directions file from one fixel directory into another. More...
 
FORCE_INLINE void copy_index_and_directions_file (const std::string &input_directory, const std::string &output_directory)
 
FORCE_INLINE void copy_all_data_files (const std::string &input_directory, const std::string &output_directory)
 Copy all data files in a fixel directory into another directory. Data files do not include the index or directions file. More...
 
template<class ValueType >
Image< ValueType > open_fixel_data_file (const std::string &input_file)
 open a data file. checks that a user has not input a fixel directory or index image More...
 
const std::string n_fixels_key ("nfixels")
 
template<class IndexType >
FORCE_INLINE LoopFixelsInVoxel Loop (IndexType &index)
 

Variables

const std::initializer_list< const std::string > supported_sparse_formats { ".mif", ".nii", ".mif.gz" , ".nii.gz" }
 

Typedef Documentation

◆ index_type

using MR::Fixel::index_type = typedef uint32_t

Definition at line 25 of file types.h.

Function Documentation

◆ check_data_file()

template<class HeaderType >
FORCE_INLINE void MR::Fixel::check_data_file ( const HeaderType &  in)

Definition at line 113 of file helpers.h.

◆ check_fixel_directory()

FORCE_INLINE void MR::Fixel::check_fixel_directory ( const std::string &  path,
bool  create_if_missing = false,
bool  check_if_empty = false 
)

Definition at line 190 of file helpers.h.

◆ check_fixel_size()

FORCE_INLINE void MR::Fixel::check_fixel_size ( const Header index_h,
const Header data_h 
)

Definition at line 180 of file helpers.h.

◆ check_index_image()

template<class HeaderType >
FORCE_INLINE void MR::Fixel::check_index_image ( const HeaderType &  index)

Definition at line 77 of file helpers.h.

◆ copy_all_data_files()

FORCE_INLINE void MR::Fixel::copy_all_data_files ( const std::string &  input_directory,
const std::string &  output_directory 
)

Copy all data files in a fixel directory into another directory. Data files do not include the index or directions file.

Definition at line 392 of file helpers.h.

◆ copy_directions_file()

FORCE_INLINE void MR::Fixel::copy_directions_file ( const std::string &  input_directory,
const std::string &  output_directory 
)

Copy the directions file from one fixel directory into another.

Definition at line 363 of file helpers.h.

◆ copy_fixel_file()

FORCE_INLINE void MR::Fixel::copy_fixel_file ( const std::string &  input_file_path,
const std::string &  output_directory 
)

Copy a file from one fixel directory into another.

Definition at line 329 of file helpers.h.

◆ copy_index_and_directions_file()

FORCE_INLINE void MR::Fixel::copy_index_and_directions_file ( const std::string &  input_directory,
const std::string &  output_directory 
)

Definition at line 385 of file helpers.h.

◆ copy_index_file()

FORCE_INLINE void MR::Fixel::copy_index_file ( const std::string &  input_directory,
const std::string &  output_directory 
)

Copy the index file from one fixel directory into another.

Definition at line 339 of file helpers.h.

◆ data_header_from_index()

template<class IndexHeaderType >
FORCE_INLINE Header MR::Fixel::data_header_from_index ( IndexHeaderType &  index)

Generate a header for a sparse data file (Nx1x1) using an index image as a template.

Definition at line 305 of file helpers.h.

◆ directions_header_from_index()

template<class IndexHeaderType >
FORCE_INLINE Header MR::Fixel::directions_header_from_index ( IndexHeaderType &  index)

Generate a header for a fixel directions data file (Nx3x1) using an index image as a template.

Definition at line 322 of file helpers.h.

◆ find_data_headers()

FORCE_INLINE vector< Header > MR::Fixel::find_data_headers ( const std::string &  fixel_directory_path,
const Header index_header,
const bool  include_directions = false 
)

Definition at line 236 of file helpers.h.

◆ find_directions_header()

FORCE_INLINE Header MR::Fixel::find_directions_header ( const std::string  fixel_directory_path)

Definition at line 272 of file helpers.h.

◆ find_index_header()

FORCE_INLINE Header MR::Fixel::find_index_header ( const std::string &  fixel_directory_path)

Definition at line 214 of file helpers.h.

◆ fixels_match()

template<class IndexHeaderType , class DataHeaderType >
FORCE_INLINE bool MR::Fixel::fixels_match ( const IndexHeaderType &  index_header,
const DataHeaderType &  data_header 
)

Definition at line 152 of file helpers.h.

◆ get_fixel_directory()

FORCE_INLINE std::string MR::Fixel::get_fixel_directory ( const std::string &  fixel_file)

Definition at line 119 of file helpers.h.

◆ get_number_of_fixels()

template<class IndexHeaderType >
FORCE_INLINE index_type MR::Fixel::get_number_of_fixels ( IndexHeaderType &  index_header)

Definition at line 129 of file helpers.h.

◆ is_data_file()

template<class HeaderType >
FORCE_INLINE bool MR::Fixel::is_data_file ( const HeaderType &  in)

Definition at line 84 of file helpers.h.

◆ is_directions_file()

template<class HeaderType >
FORCE_INLINE bool MR::Fixel::is_directions_file ( const HeaderType &  in)

Definition at line 101 of file helpers.h.

◆ is_directions_filename()

FORCE_INLINE bool MR::Fixel::is_directions_filename ( const std::string &  path)

Definition at line 90 of file helpers.h.

◆ is_index_filename()

FORCE_INLINE bool MR::Fixel::is_index_filename ( const std::string &  path)

Definition at line 58 of file helpers.h.

◆ is_index_image()

template<class HeaderType >
FORCE_INLINE bool MR::Fixel::is_index_image ( const HeaderType &  in)

Definition at line 69 of file helpers.h.

◆ Loop()

template<class IndexType >
FORCE_INLINE LoopFixelsInVoxel MR::Fixel::Loop ( IndexType &  index)

Definition at line 68 of file loop.h.

◆ n_fixels_key()

const std::string MR::Fixel::n_fixels_key ( "nfixels"  )

◆ open_fixel_data_file()

template<class ValueType >
Image< ValueType > MR::Fixel::open_fixel_data_file ( const std::string &  input_file)

open a data file. checks that a user has not input a fixel directory or index image

Definition at line 399 of file helpers.h.

Variable Documentation

◆ supported_sparse_formats

const std::initializer_list<const std::string> MR::Fixel::supported_sparse_formats { ".mif", ".nii", ".mif.gz" , ".nii.gz" }

Definition at line 27 of file keys.h.