![]() |
Bsoft 2.1.4
Bernard's software package
|
Functions for comparing projections of two oppositely handed reconstructions to images of tilted specimens. More...
#include "mg_hand.h"
#include "mg_select.h"
#include "Matrix3.h"
#include "qsort_functions.h"
#include "utilities.h"
Classes | |
struct | Hand_Stats |
Functions | |
int | field_get_handedness (Bimage *mapA, Bimage *mapB, Bmicrograph *mg1, Bmicrograph *mg2, Hand_Stats *Global, double rad_min, double rad_max, double res_min, double res_max, double AmB_min, double AB_min, int diff_out, int origins2, Bstring outimg, int fieldnum) |
int | get_handedness_from_tilt_pair (Bimage *mapA, Bimage *mapB, Bmicrograph *mg1, Bmicrograph *mg2, Bparticle *particle1, Bparticle *particle2, Hand_Stats *Pair, double rad_min, double rad_max, double res_min, double res_max, double AmB_min, double AB_min, int diff_out, int origins2, Bstring outimg, int fieldnum) |
int | hand_compute_stats (Hand_Stats *stats, int diff_out) |
int | hand_prepare_image (Bimage *p, double resmin, double resmax) |
int | hand_print_outheader (int which_one, int diff_out) |
int | hand_print_stats (Hand_Stats *stats, int which_one, int diff_out) |
int | hand_write_img (Bimage *img, Bstring imgname, Bstring outimg, int fieldnum, int num) |
Appends micrograph number, image number, and a string tag to a file name. Then it writes out an image file. More... | |
int | project_get_handedness (Bimage *mapA, Bproject *project, double *mg_ang, int *mg_index, int *mg_select, double rad_min, double rad_max, double res_min, double res_max, double AmB_min, double AB_min, int diff_out, int origins2, Bstring outimg) |
Determines handedness for all selected particles (sel > 0) in a project. More... | |
int | hand_select_consist (Bproject *project, double *mg_ang, int *mg_index, int *mg_select, int sel_consist) |
Sets consistent selection values in all (including unused) micrographs. More... | |
Variables | |
int | verbose |
Functions for comparing projections of two oppositely handed reconstructions to images of tilted specimens.
int field_get_handedness | ( | Bimage * | mapA, |
Bimage * | mapB, | ||
Bmicrograph * | mg1, | ||
Bmicrograph * | mg2, | ||
Hand_Stats * | Global, | ||
double | rad_min, | ||
double | rad_max, | ||
double | res_min, | ||
double | res_max, | ||
double | AmB_min, | ||
double | AB_min, | ||
int | diff_out, | ||
int | origins2, | ||
Bstring | outimg, | ||
int | fieldnum | ||
) |
int get_handedness_from_tilt_pair | ( | Bimage * | mapA, |
Bimage * | mapB, | ||
Bmicrograph * | mg1, | ||
Bmicrograph * | mg2, | ||
Bparticle * | particle1, | ||
Bparticle * | particle2, | ||
Hand_Stats * | Pair, | ||
double | rad_min, | ||
double | rad_max, | ||
double | res_min, | ||
double | res_max, | ||
double | AmB_min, | ||
double | AB_min, | ||
int | diff_out, | ||
int | origins2, | ||
Bstring | outimg, | ||
int | fieldnum | ||
) |
int hand_compute_stats | ( | Hand_Stats * | stats, |
int | diff_out | ||
) |
int hand_prepare_image | ( | Bimage * | p, |
double | resmin, | ||
double | resmax | ||
) |
int hand_print_outheader | ( | int | which_one, |
int | diff_out | ||
) |
int hand_print_stats | ( | Hand_Stats * | stats, |
int | which_one, | ||
int | diff_out | ||
) |
int hand_select_consist | ( | Bproject * | project, |
double * | mg_ang, | ||
int * | mg_index, | ||
int * | mg_select, | ||
int | sel_consist | ||
) |
Sets consistent selection values in all (including unused) micrographs.
*project | Project structure |
*mg_ang | angles for micrograph selection, views 1 & 2 |
*mg_index | indices for micrograph selection, views 1 & 2 |
*mg_select | micrograph selection criteria, views 1 & 2 |
sel_consist | 1 or 2, set other selection values to those of this view |
If a field-of-view contains more than two micrographs, the user can only use two of them to do the handedness determination. The unused micrographs may need their selection values set to the same as those in the used micrographs (views 1 and 2). In addition, there may be differences in the initial selection values for views 1 and 2. This routine loops through the micrographs in a field-of-view and sets all selection values to those of view 1 or 2.
Appends micrograph number, image number, and a string tag to a file name. Then it writes out an image file.
*img | Image to write out |
imgname | String tag for image, appended to file name |
outimg | Prefix and suffix for file name |
fieldnum | Index number for current field-of-view |
num | Index number for image |
int project_get_handedness | ( | Bimage * | mapA, |
Bproject * | project, | ||
double * | mg_ang, | ||
int * | mg_index, | ||
int * | mg_select, | ||
double | rad_min, | ||
double | rad_max, | ||
double | res_min, | ||
double | res_max, | ||
double | AmB_min, | ||
double | AB_min, | ||
int | diff_out, | ||
int | origins2, | ||
Bstring | outimg | ||
) |
Determines handedness for all selected particles (sel > 0) in a project.
*mapA | 3D map (hand A) |
*project | Project structure |
*mg_ang | angles for micrograph selection, views 1 & 2 |
*mg_index | indices for micrograph selection, views 1 & 2 |
*mg_select | micrograph selection criteria, views 1 & 2 |
rad_min | minimum radius for FOM calculation (pixels) |
rad_max | maximum radius for FOM calculation (pixels) |
res_min | minimum resolution for FOM calculation (angs.) |
res_max | maximum resolution for FOM calculation (angs.) |
AmB_min | |FOMA - FOMB| must be this value or greater |
AB_min | min. acceptable value for FOM of correct hand |
diff_out | output difference of measured & predicted orientations |
origins2 | flag to determine origins for second view |
outimg | prefix & suffix for output projection files |
Gets tilt-axis direction and rotation angle for a micrograph pair. Then, loops through the selected particles in pair. Sends data to function get_handedness_from_tilt_pair, where handedness is determined. Statistics are calculated for each pair and sums for global statistics are tabulated.
|
extern |