Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

EMAN::FourierReconstructorSimple2D Class Reference

This class originally added for 2D experimentation and prototying. More...

#include <reconstructor.h>

Inheritance diagram for EMAN::FourierReconstructorSimple2D:

Inheritance graph
[legend]
Collaboration diagram for EMAN::FourierReconstructorSimple2D:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 FourierReconstructorSimple2D ()
virtual ~FourierReconstructorSimple2D ()
virtual void setup ()
 Initialize the reconstructor.
virtual int insert_slice (const EMData *const slice, const Transform &euler, const float weight=1.0)
 Insert an image slice to the reconstructor.
virtual EMDatafinish (bool doift=true)
 Finish reconstruction and return the complete model.
virtual string get_name () const
 Get the unique name of this class (especially for factory based instantiation access).
virtual string get_desc () const
 Get a clear, concise description of this class.
virtual TypeDict get_param_types () const

Static Public Member Functions

ReconstructorNEW ()

Static Public Attributes

const string NAME = "fouriersimple2D"

Detailed Description

This class originally added for 2D experimentation and prototying.

It is basically a replica of the FourierReconstructor, but works in 2D

Author:
David Woolford and Phil Baldwin
Date:
early 2008

Definition at line 282 of file reconstructor.h.


Constructor & Destructor Documentation

EMAN::FourierReconstructorSimple2D::FourierReconstructorSimple2D  )  [inline]
 

Definition at line 285 of file reconstructor.h.

00285 {}

virtual EMAN::FourierReconstructorSimple2D::~FourierReconstructorSimple2D  )  [inline, virtual]
 

Definition at line 287 of file reconstructor.h.

00287 { }


Member Function Documentation

EMData * FourierReconstructorSimple2D::finish bool  doift = true  )  [virtual]
 

Finish reconstruction and return the complete model.

Parameters:
doift A flag indicating whether the returned object should be guaranteed to be in real-space (true) or should be left in whatever space the reconstructor generated
Returns:
The result 3D model.

Reimplemented from EMAN::Reconstructor.

Definition at line 244 of file reconstructor.cpp.

References EMAN::EMData::depad(), EMAN::EMData::do_ift_inplace(), EMAN::ReconstructorVolumeData::normalize_threed(), and EMAN::EMData::process_inplace().

00245 {
00246         normalize_threed();
00247 
00248         image->process_inplace("xform.fourierorigin.tocorner");
00249         image->do_ift_inplace();
00250         image->depad();
00251         image->process_inplace("xform.phaseorigin.tocenter");
00252 
00253         EMData *ret = image;
00254         image = 0;
00255         return  ret;
00256 }

virtual string EMAN::FourierReconstructorSimple2D::get_desc  )  const [inline, virtual]
 

Get a clear, concise description of this class.

Returns:
a clear, concise description of this class

Implements EMAN::FactoryBase.

Definition at line 297 of file reconstructor.h.

00297 { return "performs 2D reconstruction"; }

virtual string EMAN::FourierReconstructorSimple2D::get_name  )  const [inline, virtual]
 

Get the unique name of this class (especially for factory based instantiation access).

Returns:
the unique name of this class

Implements EMAN::FactoryBase.

Definition at line 295 of file reconstructor.h.

00295 { return NAME; }

virtual TypeDict EMAN::FourierReconstructorSimple2D::get_param_types  )  const [inline, virtual]
 

Returns:
a TypeDict defining and describing the feasible parameters of this class

Implements EMAN::FactoryBase.

Definition at line 305 of file reconstructor.h.

References EMAN::TypeDict::put().

00306                         {
00307                                 TypeDict d;
00308                                 d.put("nx", EMObject::INT, "Necessary. The x dimension of the input images.");
00309 //                              d.put("sym", EMObject::STRING, "Symmetry - assumed to be C1 if not specified");
00310                                 return d;
00311                         }

virtual int EMAN::FourierReconstructorSimple2D::insert_slice const EMData *const   slice,
const Transform euler,
const float  weight = 1.0
[virtual]
 

Insert an image slice to the reconstructor.

To insert multiple image slices, call this function multiple times.

Parameters:
slice Image slice.
euler Euler angle of this image slice.
weight A weighting factor for this slice, generally the number of particles in a class-average. May be ignored by some reconstructors
Returns:
0 if OK. 1 if error.

Reimplemented from EMAN::Reconstructor.

Reconstructor* EMAN::FourierReconstructorSimple2D::NEW  )  [inline, static]
 

Definition at line 299 of file reconstructor.h.

00300                         {
00301                                 return new FourierReconstructorSimple2D();
00302                         }

void FourierReconstructorSimple2D::setup  )  [virtual]
 

Initialize the reconstructor.

Implements EMAN::Reconstructor.

Definition at line 106 of file reconstructor.cpp.

References InvalidValueException, is_fftodd(), EMAN::EMData::set_complex(), EMAN::Dict::set_default(), EMAN::EMData::set_fftodd(), EMAN::EMData::set_ri(), and EMAN::EMData::set_size().

00107 {
00108         nx = params.set_default("nx",0);
00109 
00110         if ( nx < 0 ) throw InvalidValueException(nx, "nx must be positive");
00111 
00112         bool is_fftodd = (nx % 2 == 1);
00113 
00114         ny = nx;
00115         nx += 2-is_fftodd;
00116 
00117         image = new EMData();
00118         image->set_size(nx, ny);
00119         image->set_complex(true);
00120         image->set_fftodd(is_fftodd);
00121         image->set_ri(true);
00122 
00123         tmp_data = new EMData();
00124         tmp_data->set_size(nx/2, nx);
00125 }


Member Data Documentation

const string FourierReconstructorSimple2D::NAME = "fouriersimple2D" [static]
 

Definition at line 79 of file reconstructor.cpp.


The documentation for this class was generated from the following files:
Generated on Tue Jun 11 13:49:23 2013 for EMAN2 by  doxygen 1.3.9.1