aimsdata 6.0.0
Neuroimaging data handling
aims::BucketMap< T > Class Template Reference

An alternate, ordered, representation for buckets (voxels lists). More...

#include <aims/bucket/bucketMap.h>

Inheritance diagram for aims::BucketMap< T >:
Collaboration diagram for aims::BucketMap< T >:

Public Types

typedef std::map< int, std::map< Point3d, T, BucketMapLess > > BaseMap
 
typedef std::map< Point3d, T, BucketMapLessBucket
 
typedef std::map< int, Bucket >::iterator iterator
 
typedef std::map< int, Bucket >::const_iterator const_iterator
 
- Public Types inherited from carto::RCObject
typedef int RefCounterType
 

Public Member Functions

 BucketMap ()
 
 BucketMap (const BucketMap< T > &other)
 
 BucketMap (const AimsBucket< T > &)
 build from AimsBucket
 
virtual ~BucketMap ()
 
BucketMap< T > & operator= (const AimsBucket< T > &)
 
void insert (const Point3d &pos, const T &item)
 Function redefined to omit time.
 
void insert (const std::pair< const Point3d, T > &item)
 Function redefined to omit time, looks more like STL maps.
 
void erase (const Point3d &pos)
 Function redefined to omit time.
 
void merge (const BucketMap< T > &)
 
float sizeX () const
 returns the X resolution in mm
 
float sizeY () const
 returns the Y resolution in mm
 
float sizeZ () const
 returns the Z resolution in mm
 
float sizeT () const
 returns the T resolution in s
 
std::vector< float > getVoxelSize () const
 
void setSizeX (float sizex)
 sets the X resolution of the data in mm
 
void setSizeY (float sizey)
 sets the Y resolution of the data in mm
 
void setSizeZ (float sizez)
 sets the Z resolution of the data in mm
 
void setSizeT (float sizet)
 sets the T resolution of the data in s
 
void setSizeXYZT (float sizex, float sizey, float sizez, float sizet)
 sets X,Y,Z and T resolutions of the data
 
void setSizeXYZT (const std::vector< float > &vsize)
 
void setVoxelSize (float sizex, float sizey, float sizez, float sizet)
 
void setVoxelSize (const std::vector< float > &vsize)
 
const aims::PythonHeaderheader () const
 
aims::PythonHeaderheader ()
 
void setHeader (const aims::PythonHeader &hdr)
 
- Public Member Functions inherited from carto::RCObject
 RCObject ()
 
 RCObject (const RCObject &)
 
RCObjectoperator= (const RCObject &)
 
virtual ~RCObject ()
 

Protected Attributes

aims::PythonHeader _header
 

Detailed Description

template<class T>
class aims::BucketMap< T >

An alternate, ordered, representation for buckets (voxels lists).

Compared to AimsBucket, this version stores points in an ordered map, sorted by (z,y,x) key.

Conversion operator makes it easy to transform an AimsBucket to a BucketMap and vice versa

Definition at line 96 of file bucketMap.h.

Member Typedef Documentation

◆ BaseMap

template<class T>
typedef std::map< int , std::map< Point3d, T, BucketMapLess > > aims::BucketMap< T >::BaseMap

Definition at line 101 of file bucketMap.h.

◆ Bucket

template<class T>
typedef std::map< Point3d, T, BucketMapLess > aims::BucketMap< T >::Bucket

Definition at line 102 of file bucketMap.h.

◆ const_iterator

template<class T>
typedef std::map<int,Bucket>::const_iterator aims::BucketMap< T >::const_iterator

Definition at line 104 of file bucketMap.h.

◆ iterator

template<class T>
typedef std::map<int,Bucket>::iterator aims::BucketMap< T >::iterator

Definition at line 103 of file bucketMap.h.

Constructor & Destructor Documentation

◆ BucketMap() [1/3]

template<class T>
aims::BucketMap< T >::BucketMap ( )
inline

Definition at line 106 of file bucketMap.h.

Referenced by merge().

◆ BucketMap() [2/3]

template<class T>
aims::BucketMap< T >::BucketMap ( const BucketMap< T > & other)
inline

Definition at line 108 of file bucketMap.h.

◆ BucketMap() [3/3]

template<class T>
aims::BucketMap< T >::BucketMap ( const AimsBucket< T > & other)
inline

build from AimsBucket

Definition at line 350 of file bucketMap.h.

References _header, and header().

◆ ~BucketMap()

template<class T>
virtual aims::BucketMap< T >::~BucketMap ( )
inlinevirtual

Definition at line 113 of file bucketMap.h.

Member Function Documentation

◆ erase()

template<class T>
void aims::BucketMap< T >::erase ( const Point3d & pos)
inline

Function redefined to omit time.

Definition at line 208 of file bucketMap.h.

Referenced by aims::FileFormatDictionary< T >::unregisterFormat().

◆ getVoxelSize()

template<class T>
std::vector< float > aims::BucketMap< T >::getVoxelSize ( ) const
inline

Definition at line 224 of file bucketMap.h.

References _header.

◆ header() [1/2]

template<class T>
aims::PythonHeader & aims::BucketMap< T >::header ( )
inline

Definition at line 156 of file bucketMap.h.

◆ header() [2/2]

◆ insert() [1/2]

template<class T>
void aims::BucketMap< T >::insert ( const Point3d & pos,
const T & item )
inline

Function redefined to omit time.

Definition at line 194 of file bucketMap.h.

Referenced by merge().

◆ insert() [2/2]

template<class T>
void aims::BucketMap< T >::insert ( const std::pair< const Point3d, T > & item)
inline

Function redefined to omit time, looks more like STL maps.

Definition at line 201 of file bucketMap.h.

◆ merge()

template<class T>
void aims::BucketMap< T >::merge ( const BucketMap< T > & bck)
inline

Definition at line 215 of file bucketMap.h.

References BucketMap(), and insert().

◆ operator=()

template<class T>
BucketMap< T > & aims::BucketMap< T >::operator= ( const AimsBucket< T > & other)
inline

Definition at line 358 of file bucketMap.h.

References _header, and AimsBucket< T >::header().

◆ setHeader()

◆ setSizeT()

template<class T>
void aims::BucketMap< T >::setSizeT ( float sizet)
inline

sets the T resolution of the data in s

Definition at line 314 of file bucketMap.h.

References _header.

◆ setSizeX()

template<class T>
void aims::BucketMap< T >::setSizeX ( float sizex)
inline

sets the X resolution of the data in mm

Definition at line 275 of file bucketMap.h.

References _header.

◆ setSizeXYZT() [1/2]

template<class T>
void aims::BucketMap< T >::setSizeXYZT ( const std::vector< float > & vsize)
inline

Definition at line 340 of file bucketMap.h.

References _header.

◆ setSizeXYZT() [2/2]

template<class T>
void aims::BucketMap< T >::setSizeXYZT ( float sizex,
float sizey,
float sizez,
float sizet )
inline

sets X,Y,Z and T resolutions of the data

Definition at line 327 of file bucketMap.h.

References _header.

Referenced by carto::RawConverter< aims::BucketMap< INP >, aims::BucketMap< OUTP > >::convert(), and aims::maskWithVolume().

◆ setSizeY()

template<class T>
void aims::BucketMap< T >::setSizeY ( float sizey)
inline

sets the Y resolution of the data in mm

Definition at line 288 of file bucketMap.h.

References _header.

◆ setSizeZ()

template<class T>
void aims::BucketMap< T >::setSizeZ ( float sizez)
inline

sets the Z resolution of the data in mm

Definition at line 301 of file bucketMap.h.

References _header.

◆ setVoxelSize() [1/2]

template<class T>
void aims::BucketMap< T >::setVoxelSize ( const std::vector< float > & vsize)
inline

Definition at line 152 of file bucketMap.h.

◆ setVoxelSize() [2/2]

template<class T>
void aims::BucketMap< T >::setVoxelSize ( float sizex,
float sizey,
float sizez,
float sizet )
inline

Definition at line 149 of file bucketMap.h.

◆ sizeT()

◆ sizeX()

◆ sizeY()

◆ sizeZ()

Member Data Documentation

◆ _header

template<class T>
aims::PythonHeader aims::BucketMap< T >::_header
protected

The documentation for this class was generated from the following files: