Xmipp  v3.23.11-Nereus
Public Types | Public Member Functions | Public Attributes | List of all members

#include <project.h>

Collaboration diagram for PROJECT_Side_Info:
Collaboration graph
[legend]

Public Types

enum  PhantomType { VOXEL, XMIPP, PDB }
 Types of phantom: voxel, Xmipp, PDB. More...
 

Public Member Functions

void produce_Side_Info (ParametersProjection &prm, ProgProject &prog_prm)
 

Public Attributes

MetaDataVec DF
 Document File for the projecting angles. Order: rot, tilt, psi. More...
 
PhantomType phantomMode
 Projecting from a voxel volume, Xmipp description or PDB? More...
 
Image< double > phantomVol
 Phantom Xmipp volume. More...
 
Phantom phantomDescr
 Phantom mathematical description. More...
 
PDBPhantom phantomPDB
 Phantom PDB. More...
 
AtomInterpolator interpolator
 Atom interpolator. More...
 
double paddFactor
 The padding factor for Fourier projection. More...
 
double maxFrequency
 The maximum frequency for pixels. More...
 
int BSplineDeg
 The type of interpolation (NEAR. More...
 
bool doCrystal
 Is this a crystal projection. More...
 

Detailed Description

Project program Side information. This class contains side necessary information for the Project program. This information can be obtained from the parameters and is basically the Xmipp volume or phantom description plus a flag saying which of the two is valid.

Definition at line 215 of file project.h.

Member Enumeration Documentation

◆ PhantomType

Types of phantom: voxel, Xmipp, PDB.

Enumerator
VOXEL 
XMIPP 
PDB 

Definition at line 221 of file project.h.

Member Function Documentation

◆ produce_Side_Info()

void PROJECT_Side_Info::produce_Side_Info ( ParametersProjection prm,
ProgProject prog_prm 
)

Produce Project Side information. This function produce the side information from the project program parameters. Basically it loads the phantom, sets the phantom mode to voxel or mathematical description and generates or read the projection angles.

Definition at line 871 of file project.cpp.

873 {
874  // Generate Projection angles
875  if (!prog_prm.singleProjection)
876  Assign_angles(DF, prm, prog_prm.fn_sym);
877  else
878  {
879  size_t DFid=DF.addObject();
880  DF.setValue(MDL_ANGLE_ROT,prog_prm.rotSingle,DFid);
881  DF.setValue(MDL_ANGLE_TILT,prog_prm.tiltSingle,DFid);
882  DF.setValue(MDL_ANGLE_PSI,prog_prm.psiSingle,DFid);
883  DF.setValue(MDL_SHIFT_X,prog_prm.xShift,DFid);
884  DF.setValue(MDL_SHIFT_Y,prog_prm.yShift,DFid);
885  }
886 
887  // Load Phantom and set working mode
888  if (prog_prm.fnPhantom.isMetaData())
889  {
890  phantomDescr.read(prog_prm.fnPhantom);
891  phantomMode = XMIPP;
892  if (prog_prm.singleProjection)
893  {
894  if (prog_prm.projSize==-1)
896  else
897  prm.proj_Xdim=prm.proj_Ydim=prog_prm.projSize;
898  }
899  }
900  else if (prog_prm.fnPhantom.getExtension()=="pdb")
901  {
902  phantomPDB.read(prog_prm.fnPhantom);
903  for (int i=0; i<phantomPDB.atomList.size(); i++)
904  {
905  phantomPDB.atomList[i].x /=prog_prm.samplingRate;
906  phantomPDB.atomList[i].y /=prog_prm.samplingRate;
907  phantomPDB.atomList[i].z /=prog_prm.samplingRate;
908  }
909  int M=ROUND(prog_prm.samplingRate/prog_prm.highTs);
910  interpolator.setup(M,prog_prm.samplingRate/M,true);
911  phantomMode = PDB;
912  if (prog_prm.singleProjection)
913  {
914  if (prog_prm.projSize==-1)
915  REPORT_ERROR(ERR_ARG_MISSING,"--xdim");
916  else
917  prm.proj_Xdim=prm.proj_Ydim=prog_prm.projSize;
918  }
919  }
920  else
921  {
922  phantomVol.read(prog_prm.fnPhantom);
923  phantomVol().setXmippOrigin();
924  phantomMode = VOXEL;
925  if (prog_prm.singleProjection)
926  {
927  if (prog_prm.projSize==-1)
928  prm.proj_Xdim=prm.proj_Ydim=XSIZE(phantomVol());
929  else
930  prm.proj_Xdim=prm.proj_Ydim=prog_prm.projSize;
931  }
932  }
933  paddFactor = prog_prm.paddFactor;
934  maxFrequency = prog_prm.maxFrequency;
935  BSplineDeg = prog_prm.BSplineDeg;
936 }
void read(const FileName &fnPDB)
Read phantom from either a PDB of CIF file.
Definition: pdb.cpp:503
Argument missing.
Definition: xmipp_error.h:114
double highTs
High sampling rate: Only used for PDB projections.
Definition: project.h:65
Rotation angle of an image (double,degrees)
double paddFactor
The padding factor for Fourier projection.
Definition: project.h:83
int proj_Ydim
Projection Ydim.
Definition: project.h:163
#define REPORT_ERROR(nerr, ErrormMsg)
Definition: xmipp_error.h:211
bool singleProjection
Single projection.
Definition: project.h:69
int BSplineDeg
The type of interpolation (NEAR.
Definition: project.h:237
int Assign_angles(MetaDataVec &DF, const ParametersProjection &prm, const FileName &fn_sym)
Definition: project.cpp:801
Tilting angle of an image (double,degrees)
Phantom phantomDescr
Phantom mathematical description.
Definition: project.h:227
PDBPhantom phantomPDB
Phantom PDB.
Definition: project.h:229
Shift for the image in the X axis (double)
PhantomType phantomMode
Projecting from a voxel volume, Xmipp description or PDB?
Definition: project.h:223
Special label to be used when gathering MDs in MpiMetadataPrograms.
int proj_Xdim
Projection Xdim.
Definition: project.h:161
double maxFrequency
The maximum frequency for pixels.
Definition: project.h:235
double maxFrequency
The maximum frequency for Fourier projection.
Definition: project.h:85
AtomInterpolator interpolator
Atom interpolator.
Definition: project.h:231
double xShift
Definition: project.h:77
#define i
void setup(int m, double hights, bool computeProjection=false)
Definition: pdb.cpp:1402
double yShift
Definition: project.h:79
double tiltSingle
Tilt angle of a single projection.
Definition: project.h:73
String getExtension() const
Image< double > phantomVol
Phantom Xmipp volume.
Definition: project.h:225
double rotSingle
Rotational angle of a single projection.
Definition: project.h:71
bool setValue(const MDObject &mdValueIn, size_t id)
double paddFactor
The padding factor for Fourier projection.
Definition: project.h:233
size_t addObject() override
double psiSingle
Psi angle of a single projection.
Definition: project.h:75
#define XSIZE(v)
FileName fn_sym
Symmetry file.
Definition: project.h:59
#define ROUND(x)
Definition: xmipp_macros.h:210
void read(const FileName &fn_phantom, bool apply_scale=true)
Definition: phantom.cpp:2088
int BSplineDeg
The type of interpolation (NEAR.
Definition: project.h:87
MetaDataVec DF
Document File for the projecting angles. Order: rot, tilt, psi.
Definition: project.h:219
bool isMetaData(bool failIfNotExists=true) const
std::vector< Atom > atomList
List of atoms.
Definition: pdb.h:131
int xdim
Final volume X dimension.
Definition: phantom.h:1359
int read(const FileName &name, DataMode datamode=DATA, size_t select_img=ALL_IMAGES, bool mapData=false, int mode=WRITE_READONLY)
Shift for the image in the Y axis (double)
double samplingRate
Sampling rate: Only used for PDB projections.
Definition: project.h:63
int projSize
Projection size when fnOut is given.
Definition: project.h:61
FileName fnPhantom
Definition: project.h:52

Member Data Documentation

◆ BSplineDeg

int PROJECT_Side_Info::BSplineDeg

The type of interpolation (NEAR.

Definition at line 237 of file project.h.

◆ DF

MetaDataVec PROJECT_Side_Info::DF

Document File for the projecting angles. Order: rot, tilt, psi.

Definition at line 219 of file project.h.

◆ doCrystal

bool PROJECT_Side_Info::doCrystal

Is this a crystal projection.

Definition at line 239 of file project.h.

◆ interpolator

AtomInterpolator PROJECT_Side_Info::interpolator

Atom interpolator.

Definition at line 231 of file project.h.

◆ maxFrequency

double PROJECT_Side_Info::maxFrequency

The maximum frequency for pixels.

Definition at line 235 of file project.h.

◆ paddFactor

double PROJECT_Side_Info::paddFactor

The padding factor for Fourier projection.

Definition at line 233 of file project.h.

◆ phantomDescr

Phantom PROJECT_Side_Info::phantomDescr

Phantom mathematical description.

Definition at line 227 of file project.h.

◆ phantomMode

PhantomType PROJECT_Side_Info::phantomMode

Projecting from a voxel volume, Xmipp description or PDB?

Definition at line 223 of file project.h.

◆ phantomPDB

PDBPhantom PROJECT_Side_Info::phantomPDB

Phantom PDB.

Definition at line 229 of file project.h.

◆ phantomVol

Image<double> PROJECT_Side_Info::phantomVol

Phantom Xmipp volume.

Definition at line 225 of file project.h.


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