Xmipp
v3.23.11-Nereus
|
#include <forward_zernike_subtomos.h>
Public Types | |
enum | Direction { Direction::ROTATE, Direction::UNROTATE } |
Public Member Functions | |
ProgForwardZernikeSubtomos () | |
Empty constructor. More... | |
~ProgForwardZernikeSubtomos () | |
Destructor. More... | |
void | readParams () |
Read argument from command line. More... | |
void | show () |
Show. More... | |
void | defineParams () |
Define parameters. More... | |
void | preProcess () |
void | processImage (const FileName &fnImg, const FileName &fnImgOut, const MDRow &rowIn, MDRow &rowOut) |
void | numCoefficients (int l1, int l2, int &vecSize) |
Length of coefficients vector. More... | |
void | minimizepos (int L1, int l2, Matrix1D< double > &steps) |
Determine the positions to be minimize of a vector containing spherical harmonic coefficients. More... | |
void | fillVectorTerms (int l1, int l2, Matrix1D< int > &vL1, Matrix1D< int > &vN, Matrix1D< int > &vL2, Matrix1D< int > &vM) |
Zernike and SPH coefficients allocation. More... | |
void | deformVol (MultidimArray< double > &mVD, const MultidimArray< double > &mV, double &def, double rot, double tilt, double psi) |
Deform a volumen using Zernike-Spherical harmonic basis. More... | |
void | updateCTFImage (double defocusU, double defocusV, double angle) |
double | transformImageSph (double *pclnm) |
template<Direction DIRECTION> | |
void | rotateCoefficients () |
virtual void | finishProcessing () |
virtual void | writeImageParameters (MDRow &row) |
virtual void | checkPoint () |
For very long programs, it may be needed to write checkpoints. More... | |
Matrix1D< double > | weightsInterpolation3D (double x, double y, double z) |
void | splattingAtPos (std::array< double, 3 > r, double weight, MultidimArray< double > &mP, const MultidimArray< double > &mV) |
void | rotatePositions (double rot, double tilt, double psi) |
void | preComputeDF () |
Public Member Functions inherited from XmippMetadataProgram | |
MetaData * | getInputMd () |
MetaDataVec & | getOutputMd () |
XmippMetadataProgram () | |
Empty constructor. More... | |
virtual int | tryRead (int argc, const char **argv, bool reportErrors=true) |
virtual void | init () |
virtual void | setup (MetaData *md, const FileName &o="", const FileName &oroot="", bool applyGeo=false, MDLabel label=MDL_IMAGE) |
virtual | ~XmippMetadataProgram () |
void | setMode (WriteModeMetaData _mode) |
void | setupRowOut (const FileName &fnImgIn, const MDRow &rowIn, const FileName &fnImgOut, MDRow &rowOut) const |
Prepare rowout. More... | |
virtual void | wait () |
Wait for the distributor to finish. More... | |
virtual void | run () |
Run over all images. More... | |
Public Member Functions inherited from XmippProgram | |
const char * | getParam (const char *param, int arg=0) |
const char * | getParam (const char *param, const char *subparam, int arg=0) |
int | getIntParam (const char *param, int arg=0) |
int | getIntParam (const char *param, const char *subparam, int arg=0) |
double | getDoubleParam (const char *param, int arg=0) |
double | getDoubleParam (const char *param, const char *subparam, int arg=0) |
float | getFloatParam (const char *param, int arg=0) |
float | getFloatParam (const char *param, const char *subparam, int arg=0) |
void | getListParam (const char *param, StringVector &list) |
int | getCountParam (const char *param) |
bool | checkParam (const char *param) |
bool | existsParam (const char *param) |
void | addParamsLine (const String &line) |
void | addParamsLine (const char *line) |
ParamDef * | getParamDef (const char *param) const |
virtual void | quit (int exit_code=0) const |
virtual int | tryRun () |
void | initProgress (size_t total, size_t stepBin=60) |
void | setProgress (size_t value=0) |
void | endProgress () |
void | processDefaultComment (const char *param, const char *left) |
void | setDefaultComment (const char *param, const char *comment) |
void | setProgramName (const char *name) |
void | addUsageLine (const char *line, bool verbatim=false) |
void | clearUsage () |
void | addExampleLine (const char *example, bool verbatim=true) |
void | addSeeAlsoLine (const char *seeAlso) |
void | addKeywords (const char *keywords) |
const char * | name () const |
virtual void | usage (int verb=0) const |
virtual void | usage (const String ¶m, int verb=2) |
int | version () const |
virtual void | read (int argc, const char **argv, bool reportErrors=true) |
virtual void | read (int argc, char **argv, bool reportErrors=true) |
void | read (const String &argumentsLine) |
XmippProgram () | |
XmippProgram (int argc, const char **argv) | |
virtual | ~XmippProgram () |
Protected Member Functions | |
void | createWorkFiles () |
Protected Member Functions inherited from XmippMetadataProgram | |
virtual void | initComments () |
virtual void | postProcess () |
virtual bool | getImageToProcess (size_t &objId, size_t &objIndex) |
void | show () const override |
virtual void | startProcessing () |
virtual void | writeOutput () |
virtual void | showProgress () |
virtual void | defineLabelParam () |
Protected Member Functions inherited from XmippProgram | |
void | defineCommons () |
Protected Member Functions inherited from Rerunable | |
Rerunable (const FileName &fn) | |
virtual void | createWorkFiles (bool resume, MetaData *md) |
const FileName & | getFileName () const |
void | setFileName (const FileName &fn) |
Additional Inherited Members | |
Protected Attributes inherited from XmippMetadataProgram | |
WriteModeMetaData | mode |
Metadata writing mode: OVERWRITE, APPEND. More... | |
FileName | oext |
Output extension and root. More... | |
FileName | oroot |
MDLabel | image_label |
MDLabel to be used to read/write images, usually will be MDL_IMAGE. More... | |
bool | produces_an_output |
Indicate that a unique final output is produced. More... | |
bool | produces_a_metadata |
Indicate that the unique final output file is a Metadata. More... | |
bool | each_image_produces_an_output |
Indicate that an output is produced for each image in the input. More... | |
bool | allow_apply_geo |
bool | decompose_stacks |
Input Metadata will treat a stack file as a set of images instead of a unique file. More... | |
bool | delete_output_stack |
Delete previous output stack file prior to process images. More... | |
bool | get_image_info |
Get the input image file dimensions to further operations. More... | |
bool | save_metadata_stack |
Save the associated output metadata when output file is a stack. More... | |
bool | track_origin |
Include the original input image filename in the output stack. More... | |
bool | keep_input_columns |
Keep input metadata columns. More... | |
bool | remove_disabled |
Remove disabled images from the input selfile. More... | |
bool | allow_time_bar |
Show process time bar. More... | |
bool | input_is_metadata |
Input is a metadata. More... | |
bool | single_image |
Input is a single image. More... | |
bool | input_is_stack |
Input is a stack. More... | |
bool | output_is_stack |
Output is a stack. More... | |
bool | create_empty_stackfile |
bool | delete_mdIn |
size_t | time_bar_step |
Some time bar related counters. More... | |
size_t | time_bar_size |
size_t | time_bar_done |
Protected Attributes inherited from XmippProgram | |
int | errorCode |
ProgramDef * | progDef |
Program definition and arguments parser. More... | |
std::map< String, CommentList > | defaultComments |
int | argc |
Original command line arguments. More... | |
const char ** | argv |
Predict Continuous Parameters.
Definition at line 43 of file forward_zernike_subtomos.h.
|
strong |
Enumerator | |
---|---|
ROTATE | |
UNROTATE |
Definition at line 162 of file forward_zernike_subtomos.h.
ProgForwardZernikeSubtomos::ProgForwardZernikeSubtomos | ( | ) |
Empty constructor.
Definition at line 35 of file forward_zernike_subtomos.cpp.
|
default |
Destructor.
|
virtual |
For very long programs, it may be needed to write checkpoints.
Reimplemented from XmippMetadataProgram.
Reimplemented in MpiProgForwardZernikeSubtomos.
Definition at line 622 of file forward_zernike_subtomos.cpp.
|
inlineprotected |
Definition at line 231 of file forward_zernike_subtomos.h.
|
virtual |
Define parameters.
Reimplemented from XmippMetadataProgram.
Definition at line 105 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::deformVol | ( | MultidimArray< double > & | mVD, |
const MultidimArray< double > & | mV, | ||
double & | def, | ||
double | rot, | ||
double | tilt, | ||
double | psi | ||
) |
Deform a volumen using Zernike-Spherical harmonic basis.
Definition at line 729 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::fillVectorTerms | ( | int | l1, |
int | l2, | ||
Matrix1D< int > & | vL1, | ||
Matrix1D< int > & | vN, | ||
Matrix1D< int > & | vL2, | ||
Matrix1D< int > & | vM | ||
) |
Zernike and SPH coefficients allocation.
Definition at line 673 of file forward_zernike_subtomos.cpp.
|
virtual |
Write the final parameters.
Reimplemented from XmippMetadataProgram.
Reimplemented in MpiProgForwardZernikeSubtomos.
Definition at line 249 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::minimizepos | ( | int | L1, |
int | l2, | ||
Matrix1D< double > & | steps | ||
) |
Determine the positions to be minimize of a vector containing spherical harmonic coefficients.
Definition at line 646 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::numCoefficients | ( | int | l1, |
int | l2, | ||
int & | vecSize | ||
) |
void ProgForwardZernikeSubtomos::preComputeDF | ( | ) |
Definition at line 1072 of file forward_zernike_subtomos.cpp.
|
virtual |
Produce side info. An exception is thrown if any of the files is not found
Reimplemented from XmippMetadataProgram.
Definition at line 139 of file forward_zernike_subtomos.cpp.
|
virtual |
Predict angles and shift. At the input the pose parameters must have an initial guess of the parameters. At the output they have the estimated pose.
Implements XmippMetadataProgram.
Definition at line 416 of file forward_zernike_subtomos.cpp.
|
virtual |
Read argument from command line.
Reimplemented from XmippMetadataProgram.
Definition at line 46 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::rotateCoefficients | ( | ) |
Definition at line 706 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::rotatePositions | ( | double | rot, |
double | tilt, | ||
double | psi | ||
) |
Definition at line 1028 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::show | ( | ) |
Show.
Definition at line 76 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::splattingAtPos | ( | std::array< double, 3 > | r, |
double | weight, | ||
MultidimArray< double > & | mP, | ||
const MultidimArray< double > & | mV | ||
) |
Definition at line 961 of file forward_zernike_subtomos.cpp.
double ProgForwardZernikeSubtomos::transformImageSph | ( | double * | pclnm | ) |
Definition at line 255 of file forward_zernike_subtomos.cpp.
void ProgForwardZernikeSubtomos::updateCTFImage | ( | double | defocusU, |
double | defocusV, | ||
double | angle | ||
) |
Definition at line 696 of file forward_zernike_subtomos.cpp.
Matrix1D< double > ProgForwardZernikeSubtomos::weightsInterpolation3D | ( | double | x, |
double | y, | ||
double | z | ||
) |
Definition at line 930 of file forward_zernike_subtomos.cpp.
|
virtual |
Write the parameters found for one image
Definition at line 596 of file forward_zernike_subtomos.cpp.
Matrix2D<double> ProgForwardZernikeSubtomos::A |
Definition at line 114 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::algn_params |
Definition at line 85 of file forward_zernike_subtomos.h.
struct blobtype ProgForwardZernikeSubtomos::blob |
Definition at line 145 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::blob_r |
Definition at line 146 of file forward_zernike_subtomos.h.
Matrix1D<double> ProgForwardZernikeSubtomos::clnm |
Definition at line 132 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::correlation |
Definition at line 141 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::ctf_params |
Definition at line 87 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::currentAngle |
Definition at line 126 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::currentDefocusU |
Definition at line 126 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::currentDefocusV |
Definition at line 126 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaDefocusAngle |
Definition at line 124 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaDefocusU |
Definition at line 124 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaDefocusV |
Definition at line 124 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaPsi |
Definition at line 116 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaRot |
Definition at line 116 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaTilt |
Definition at line 116 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaX |
Definition at line 118 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaY |
Definition at line 118 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::deltaZ |
Definition at line 118 of file forward_zernike_subtomos.h.
MultidimArray<double> ProgForwardZernikeSubtomos::df |
Definition at line 156 of file forward_zernike_subtomos.h.
FourierFilter ProgForwardZernikeSubtomos::filter |
Definition at line 111 of file forward_zernike_subtomos.h.
FourierFilter ProgForwardZernikeSubtomos::FilterCTF |
Definition at line 128 of file forward_zernike_subtomos.h.
FourierFilter ProgForwardZernikeSubtomos::filterMW |
Definition at line 112 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::flagEnabled |
Definition at line 89 of file forward_zernike_subtomos.h.
FileName ProgForwardZernikeSubtomos::fnImage |
Definition at line 102 of file forward_zernike_subtomos.h.
FileName ProgForwardZernikeSubtomos::fnMaskR |
Filename of the reference volume mask
Definition at line 49 of file forward_zernike_subtomos.h.
FileName ProgForwardZernikeSubtomos::fnOutDir |
Output directory.
Definition at line 51 of file forward_zernike_subtomos.h.
FileName ProgForwardZernikeSubtomos::fnVolR |
Filename of the reference volume
Definition at line 47 of file forward_zernike_subtomos.h.
Matrix1D<double> ProgForwardZernikeSubtomos::gaussianProjectionTable |
Definition at line 150 of file forward_zernike_subtomos.h.
Matrix1D<double> ProgForwardZernikeSubtomos::gaussianProjectionTable2 |
Definition at line 153 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::hasCTF |
Definition at line 122 of file forward_zernike_subtomos.h.
Image<double> ProgForwardZernikeSubtomos::I |
Definition at line 105 of file forward_zernike_subtomos.h.
std::vector<size_t> ProgForwardZernikeSubtomos::idx_z_clnm |
Definition at line 157 of file forward_zernike_subtomos.h.
Image<double> ProgForwardZernikeSubtomos::Ifiltered |
Definition at line 106 of file forward_zernike_subtomos.h.
Image<double> ProgForwardZernikeSubtomos::Ifilteredp |
Definition at line 107 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::ignoreCTF |
Definition at line 73 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::L1 |
Degrees of Zernike polynomials and spherical harmonics
Definition at line 53 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::L2 |
Definition at line 53 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::lambda |
Definition at line 79 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::loop_step |
Definition at line 143 of file forward_zernike_subtomos.h.
MultidimArray<int> ProgForwardZernikeSubtomos::mask3D |
Definition at line 98 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::maxAngularChange |
Maximum angular change allowed
Definition at line 59 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::maxResol |
Maximum frequency (A)
Definition at line 61 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::maxShift |
Maximum shift allowed
Definition at line 57 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::num_images |
Definition at line 83 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_defocusAngle |
Definition at line 124 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_defocusU |
Definition at line 124 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_defocusV |
Definition at line 124 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::old_flip |
Definition at line 120 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_psi |
Definition at line 116 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_rot |
Definition at line 116 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_shiftX |
Definition at line 118 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_shiftY |
Definition at line 118 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_shiftZ |
Definition at line 118 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::old_tilt |
Definition at line 116 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::optimizeAlignment |
Definition at line 67 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::optimizeDefocus |
Definition at line 71 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::optimizeDeformation |
Definition at line 69 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::optimizeRadius |
Definition at line 75 of file forward_zernike_subtomos.h.
Matrix1D<double> ProgForwardZernikeSubtomos::p |
Definition at line 88 of file forward_zernike_subtomos.h.
Image<double> ProgForwardZernikeSubtomos::P |
Definition at line 109 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::phaseFlipped |
Definition at line 77 of file forward_zernike_subtomos.h.
Matrix1D<double> ProgForwardZernikeSubtomos::prev_clnm |
Definition at line 132 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::prior_deformation |
Definition at line 136 of file forward_zernike_subtomos.h.
Matrix2D<double> ProgForwardZernikeSubtomos::R |
Definition at line 159 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::resume |
Resume computations
Definition at line 96 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::Rmax |
Maximum radius
Definition at line 65 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::RmaxDef |
Definition at line 81 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::showOptimization |
Definition at line 139 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::sigma4 |
Definition at line 148 of file forward_zernike_subtomos.h.
Matrix1D<double> ProgForwardZernikeSubtomos::steps_cp |
Definition at line 134 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::sumV |
Definition at line 137 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::t1 |
Definition at line 92 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::t2 |
Definition at line 92 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::totalDeformation |
Definition at line 136 of file forward_zernike_subtomos.h.
double ProgForwardZernikeSubtomos::Ts |
Sampling rate
Definition at line 63 of file forward_zernike_subtomos.h.
bool ProgForwardZernikeSubtomos::useCTF |
Definition at line 90 of file forward_zernike_subtomos.h.
Image<double> ProgForwardZernikeSubtomos::V |
Definition at line 104 of file forward_zernike_subtomos.h.
MultidimArray<int> ProgForwardZernikeSubtomos::V_mask |
Definition at line 98 of file forward_zernike_subtomos.h.
Image<double> ProgForwardZernikeSubtomos::Vdeformed |
Definition at line 104 of file forward_zernike_subtomos.h.
int ProgForwardZernikeSubtomos::vecSize |
Definition at line 130 of file forward_zernike_subtomos.h.
Matrix1D<int> ProgForwardZernikeSubtomos::vL1 |
Zernike and SPH coefficients vectors
Definition at line 55 of file forward_zernike_subtomos.h.
Matrix1D<int> ProgForwardZernikeSubtomos::vL2 |
Definition at line 55 of file forward_zernike_subtomos.h.
Matrix1D<int> ProgForwardZernikeSubtomos::vM |
Definition at line 55 of file forward_zernike_subtomos.h.
Matrix1D<int> ProgForwardZernikeSubtomos::vN |
Definition at line 55 of file forward_zernike_subtomos.h.
MultidimArray<double> ProgForwardZernikeSubtomos::vpos |
Definition at line 156 of file forward_zernike_subtomos.h.
size_t ProgForwardZernikeSubtomos::Xdim |
Definition at line 100 of file forward_zernike_subtomos.h.
std::vector<double> ProgForwardZernikeSubtomos::z_clnm_diff |
Definition at line 158 of file forward_zernike_subtomos.h.