Bsoft  2.1.0
Bernard's software package
bico.cpp File Reference

Program to analyze icosahedral subtomograms. More...

#include "mg_processing.h"
#include "mg_reconstruct.h"
#include "rwmg.h"
#include "rwimg.h"
#include "rwsymop.h"
#include "symmetry.h"
#include "linked_list.h"
#include "utilities.h"
#include "options.h"
#include "timer.h"

Go to the source code of this file.

Functions

Bimage * img_vertex_reconstruct (Bproject *project, Vector3< long > size, double maxres)
 
long project_ico_worst_vertex (Bproject *project, Bimage *pref, Bimage *pmask, Bimage *pfsmask, double hires, double lores)
 Determines the special vertex for icosahedral symmetry and returns two maps. More...
 
long project_ico_opposite_vertex (Bproject *project, Bimage *pmask, Bimage *pfsmask, double hires, double lores)
 Determines the special vertex for icosahedral symmetry and returns two maps. More...
 
long project_ico_best_c5 (Bproject *project, Bimage *pref, Bimage *pmask, Bimage *pfsmask, double hires, double lores)
 Determines the best 5-fold orientation of the vertex wrt a reference. More...
 
long project_assign_special_vertex_orientations (Bproject *project, Bproject *project_specvert)
 
long project_analyze_vertices (Bproject *project, double threshold)
 
int main (int argc, char **argv)
 
Bimage * img_read_orient_mask (Bstring &filename, Bimage *pmask, View view)
 
double img_cc (Bimage *p1, Bimage *p2, Bimage *pfsmask, double hires, double lores)
 
long particle_worst_vertex (Bparticle *vert, Bimage *pref, Bimage *pmask, Bimage *pfsmask, double hires, double lores)
 
long particle_cc_opposite_vertices (Bparticle *vert, Bimage *pmask, Bimage *pfsmask, double hires, double lores)
 
long particle_worst_opposite_vertex (Bparticle *vert, Bimage *pref, Bimage *pmask, Bimage *pfsmask, double hires, double lores)
 
long particle_best_c5 (Bparticle *part, Bimage *pref, Bimage *pmask, Bimage *pfsmask, double hires, double lores)
 

Variables

int verbose
 
fft_plan planf
 
fft_plan planb
 
const char * use []
 

Detailed Description

Program to analyze icosahedral subtomograms.

Author
Bernard Heymann
Date
Created: 20180427
Modified: 20200408

Definition in file bico.cpp.

Function Documentation

◆ img_cc()

double img_cc ( Bimage *  p1,
Bimage *  p2,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Definition at line 226 of file bico.cpp.

◆ img_read_orient_mask()

Bimage* img_read_orient_mask ( Bstring &  filename,
Bimage *  pmask,
View  view 
)

Definition at line 208 of file bico.cpp.

◆ img_vertex_reconstruct()

Bimage * img_vertex_reconstruct ( Bproject *  project,
Vector3< long >  size,
double  maxres 
)

Definition at line 250 of file bico.cpp.

◆ main()

int main ( int  argc,
char **  argv 
)

Definition at line 65 of file bico.cpp.

◆ particle_best_c5()

long particle_best_c5 ( Bparticle *  part,
Bimage *  pref,
Bimage *  pmask,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Definition at line 386 of file bico.cpp.

◆ particle_cc_opposite_vertices()

long particle_cc_opposite_vertices ( Bparticle *  vert,
Bimage *  pmask,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Definition at line 309 of file bico.cpp.

◆ particle_worst_opposite_vertex()

long particle_worst_opposite_vertex ( Bparticle *  vert,
Bimage *  pref,
Bimage *  pmask,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Definition at line 353 of file bico.cpp.

◆ particle_worst_vertex()

long particle_worst_vertex ( Bparticle *  vert,
Bimage *  pref,
Bimage *  pmask,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Definition at line 264 of file bico.cpp.

◆ project_analyze_vertices()

long project_analyze_vertices ( Bproject *  project,
double  threshold 
)

Definition at line 705 of file bico.cpp.

◆ project_assign_special_vertex_orientations()

long project_assign_special_vertex_orientations ( Bproject *  project,
Bproject *  project_specvert 
)

Definition at line 665 of file bico.cpp.

◆ project_ico_best_c5()

long project_ico_best_c5 ( Bproject *  project,
Bimage *  pref,
Bimage *  pmask,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Determines the best 5-fold orientation of the vertex wrt a reference.

Parameters
*projectparameter structure with all parameters.
*prefreference map.
*pmaskreal space mask.
*pfsmaskfrequency space mask.
hiresmaximum resolution for correlation.
loresminimum resolution for correlation.
Returns
long 1 if done, 0 on error.
The function compares opposite vertices of the twelve for every particle
to identify the pair that is most dissimilar. 
One of these is a candidate for the special vertex.
A reference map is then calculated from all the rest of the vertices.
The previously selected pair is then correlated agiants the reference
and the one with the worst coefficient selected as final candidate.
Two averages are calculated, the first for the non-special vertices,
and the second for the special vertices.

Definition at line 611 of file bico.cpp.

◆ project_ico_opposite_vertex()

long project_ico_opposite_vertex ( Bproject *  project,
Bimage *  pmask,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Determines the special vertex for icosahedral symmetry and returns two maps.

Parameters
*projectparameter structure with all parameters.
*pmaskreal space mask.
*pfsmaskfrequency space mask.
hiresmaximum resolution for correlation.
loresminimum resolution for correlation.
Returns
long 1 if done, 0 on error.
The function compares opposite vertices of the twelve for every particle
to identify the pair that is most dissimilar. 
One of these is a candidate for the special vertex.
A reference map is then calculated from all the rest of the vertices.
The previously selected pair is then correlated agiants the reference
and the one with the worst coefficient selected as final candidate.
Two averages are calculated, the first for the non-special vertices,
and the second for the special vertices.

Definition at line 520 of file bico.cpp.

◆ project_ico_worst_vertex()

long project_ico_worst_vertex ( Bproject *  project,
Bimage *  pref,
Bimage *  pmask,
Bimage *  pfsmask,
double  hires,
double  lores 
)

Determines the special vertex for icosahedral symmetry and returns two maps.

Parameters
*projectparameter structure with all parameters.
*prefreference map.
*pmaskreal space mask.
*pfsmaskfrequency space mask.
hiresmaximum resolution for correlation.
loresminimum resolution for correlation.
Returns
long 1 if done, 0 on error.
The function correlates each vertex with the reference, and selects the one
out of the twelve for each particle with the worst coefficient as the 
likely special vertex.
Two averages are calculated, the first for the non-special vertices,
and the second for the special vertices.

Definition at line 446 of file bico.cpp.

Variable Documentation

◆ planb

fft_plan planb

Definition at line 24 of file bico.cpp.

◆ planf

fft_plan planf

Definition at line 24 of file bico.cpp.

◆ use

const char* use[]
Initial value:
= {
" ",
"Usage: bico [options] tomo.star",
"-------------------------------",
"Analyzes icosahedral subtomograms.",
" ",
"Actions:",
"-find opp Type of correlation: worst, opposite, c5.",
"-analyze 0.1 Calculate statistics for vertices.",
" ",
"Parameters:",
"-verbose 7 Verbosity of output.",
"-resolution 15.6,200 Resolution limits for cross-correlation (default 0,inf).",
"-maxresolution 9.5 Maximum reconstruction resolution limit (default Nyquist).",
" ",
"Input:",
"-reference image.map Reference for cross-correlation.",
"-mask image.map Real space mask.",
"-Mask fsmask.mrc Frequency space mask (missing data).",
"-special vert.star Parameter file with special vertex orientations.",
" ",
"Output:",
"-output file.star Output parameter file.",
"-reconstruction file.ext Reconstruction file name.",
" ",
NULL
}

Definition at line 37 of file bico.cpp.

◆ verbose

int verbose
extern