EMAN2
Functions
emdata_modular.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void process_inplace (const string &processorname, const Dict &params=Dict())
 This file is a part of "emdata.h", to use functions in this file, you should "#include "emdata.h", NEVER directly include this file. More...
 
void process_inplace (Processor *p)
 Call the process_inplace with an instance od Processor, usually this instancecan be get by (in Python) Processors.get("name", {'k':v, 'k':v}) More...
 
EMData * process (const string &processorname, const Dict &params=Dict()) const
 Apply a processor with its parameters on a copy of this image, return result as a a new image. More...
 
EMData * process (Processor *p) const
 Call the process with an instance od Processor, usually this instance can be get by (in Python) Processors.get("name", {'k':v, 'k':v}) More...
 
float cmp (const string &cmpname, EMData *with, const Dict &params=Dict())
 Compare this image with another image. More...
 
EMData * align (const string &aligner_name, EMData *to_img, const Dict &params=Dict(), const string &cmp_name="", const Dict &cmp_params=Dict())
 Align this image with another image and return the result image. More...
 
vector< Dict > xform_align_nbest (const string &aligner_name, EMData *to_img, const Dict &params=Dict(), const unsigned int nsoln=1, const string &cmp_name="dot", const Dict &cmp_params=Dict())
 Align this image with another image, return the parameters of the "n best" solutions See Aligner::xform_align_nbest for more comments. More...
 
EMData * project (const string &projector_name, const Dict &params=Dict())
 Calculate the projection of this image and return the result. More...
 
EMData * project (const string &projector_name, const Transform &t3d)
 Calculate the projection of this image and return the result. More...
 
EMData * backproject (const string &projector_name, const Dict &params=Dict())
 Calculate the backprojection of this image (stack) and return the result. More...
 

Function Documentation

◆ align()

EMData * align ( const string &  aligner_name,
EMData *  to_img,
const Dict &  params = Dict(),
const string &  cmp_name = "",
const Dict &  cmp_params = Dict() 
)

Align this image with another image and return the result image.

Parameters
aligner_nameAlignment algorithm name.
to_imgThe image 'this' image aligns to.
paramsAlignment algorithm parameters in a keyed dictionary.
cmp_nameComparison algorithm used in alignment.
cmp_paramsParameter dictionary for comparison algorithm.
Exceptions
NotExistingObjectErrorIf the alignment algorithm doesn't exist.
Returns
The result image.

◆ backproject()

EMData * backproject ( const string &  projector_name,
const Dict &  params = Dict() 
)

Calculate the backprojection of this image (stack) and return the result.

Parameters
projector_nameProjection algorithm name. (Only "pawel" and "chao" have been implemented now).
paramsProjection Algorithm parameters.
Exceptions
NotExistingObjectErrorIf the projection algorithm doesn't exist.
Returns
The result image.

◆ cmp()

float cmp ( const string &  cmpname,
EMData *  with,
const Dict &  params = Dict() 
)

Compare this image with another image.

Parameters
cmpnameComparison algorithm name.
withThe image you want to compare to.
paramsComparison parameters in a keyed dictionary.
Exceptions
NotExistingObjectErrorIf the comparison algorithm doesn't exist.
Returns
comparison score. The bigger, the better.

◆ process() [1/2]

EMData * process ( const string &  processorname,
const Dict &  params = Dict() 
) const

Apply a processor with its parameters on a copy of this image, return result as a a new image.

The returned image may or may not be the same size as this image.

Parameters
processornameProcessor Name.
paramsProcessor parameters in a keyed dictionary.
Returns
the processed result, a new image
Exceptions
NotExistingObjectErrorIf the processor doesn't exist.

Referenced by EMAN::EMData::calc_ccf_masked().

◆ process() [2/2]

EMData * process ( Processor *  p) const

Call the process with an instance od Processor, usually this instance can be get by (in Python) Processors.get("name", {'k':v, 'k':v})

Parameters
pthe processor pointer

◆ process_inplace() [1/2]

void process_inplace ( const string &  processorname,
const Dict &  params = Dict() 
)

This file is a part of "emdata.h", to use functions in this file, you should "#include "emdata.h", NEVER directly include this file.

Apply a processor with its parameters on this image.

Parameters
processornameProcessor Name.
paramsProcessor parameters in a keyed dictionary.
Exceptions
NotExistingObjectErrorIf the processor doesn't exist.

Referenced by EMAN::EMData::rotate_180(), EMAN::EMData::transform(), and EMAN::EMData::translate().

◆ process_inplace() [2/2]

void process_inplace ( Processor *  p)

Call the process_inplace with an instance od Processor, usually this instancecan be get by (in Python) Processors.get("name", {'k':v, 'k':v})

Parameters
pthe processor pointer

◆ project() [1/2]

EMData * project ( const string &  projector_name,
const Dict &  params = Dict() 
)

Calculate the projection of this image and return the result.

Parameters
projector_nameProjection algorithm name.
paramsProjection Algorithm parameters.
Exceptions
NotExistingObjectErrorIf the projection algorithm doesn't exist.
Returns
The result image.

◆ project() [2/2]

EMData * project ( const string &  projector_name,
const Transform &  t3d 
)

Calculate the projection of this image and return the result.

Parameters
projector_nameProjection algorithm name.
t3dTransform object used to do projection.
Exceptions
NotExistingObjectErrorIf the projection algorithm doesn't exist.
Returns
The result image.

◆ xform_align_nbest()

vector< Dict > xform_align_nbest ( const string &  aligner_name,
EMData *  to_img,
const Dict &  params = Dict(),
const unsigned int  nsoln = 1,
const string &  cmp_name = "dot",
const Dict &  cmp_params = Dict() 
)

Align this image with another image, return the parameters of the "n best" solutions See Aligner::xform_align_nbest for more comments.

Parameters
aligner_nameAlignment algorithm name.
to_imgThe image 'this' image aligns to.
paramsAlignment algorithm parameters in a keyed dictionary.
nsolnthe number of solutions you want to receive in the return vector.
cmp_nameComparison algorithm used in alignment.
cmp_paramsParameter dictionary for comparison algorithm.
Exceptions
NotExistingObjectErrorIf the alignment algorithm doesn't exist.
Returns
an ordered vector of Dicts of length nsoln. The Dicts in the vector have keys "score" (i.e. correlation score) and "xform.align3d" (Transform containing the alignment)