Scanlinefit

Program to evaluate scanner performance of scanner by measuring deviation from 45 degree line to determine CCD curvature and pincushion parameter.

tree

tree

Input: Micrograph

Output: Diagnostic plot

Parameters

Parameter

Example (default)

Description

Micrograph

cs_scan034.tif

Input micrograph: accepted file formats (tif, .mrc, .mrcs, .spi, .hdf, .img, .hed).

Diagnostic plot

scanlinefit_diag.pdf

Output diagnostic plot: accepted file formats (pdf, .png, .bmp, .emf, .eps, .gif, .jpeg, .jpg, .ps, .raw, .rgba, .svg, .svgz, .tif, .tiff).

Sample parameter file

You may run the program in the command line by providing the parameters via a text file:

scanlinefit --f parameterfile.txt

Where the format of the parameters is:

Micrograph                               = cs_scan034.tif
Diagnostic plot                          = scanlinefit_diag.pdf

Additional parameters (intermediate level)

Parameter

Example (default)

Description

Topleft coordinates of line

(180, 2302)

Integer pair of coordinates (x,y) (accepted values min=0, max=30000).

Bottomright coordinates of line

(1889, 215)

Integer pair of coordinates (x,y) (accepted values min=0, max=30000).

Sample parameter file (intermediate level)

You may run the program in the command line by providing the parameters via a text file:

scanlinefit --f parameterfile.txt

Where the format of the parameters is:

Micrograph                               = cs_scan034.tif
Diagnostic plot                          = scanlinefit_diag.pdf
Topleft coordinates of line              = (180, 2302)
Bottomright coordinates of line          = (1889, 215)

Additional parameters (expert level)

Parameter

Example (default)

Description

Width of integration in pixels

9

Use default value: number of pixels used for line determination - otherwise use with caution (accepted values min=1, max=500).

Sample parameter file (expert level)

You may run the program in the command line by providing the parameters via a text file:

scanlinefit --f parameterfile.txt

Where the format of the parameters is:

Micrograph                               = cs_scan034.tif
Diagnostic plot                          = scanlinefit_diag.pdf
Width of integration in pixels           = 9
Topleft coordinates of line              = (180, 2302)
Bottomright coordinates of line          = (1889, 215)

Command line options

When invoking scanlinefit, you may specify any of these options:

usage: scanlinefit [-h] [--g] [--p] [--f FILENAME] [--c] [--l LOGFILENAME] [--d DIRECTORY_NAME] [--version] [input_output [input_output ...]]

Program to evaluate scanner performance of scanner by measuring deviation from 45 degree line to determine CCD curvature and pincushion parameter.

positional arguments:
  input_output          Input and output files

optional arguments:
  -h, --help            show this help message and exit
  --g, --GUI            GUI option: read input parameters from GUI
  --p, --promptuser     Prompt user option: read input parameters from prompt
  --f FILENAME, --parameterfile FILENAME
                        File option: read input parameters from FILENAME
  --c, --cmd            Command line parameter option: read only boolean input parameters from command line and all other parameters will be assigned
                        from other sources
  --l LOGFILENAME, --logfile LOGFILENAME
                        Output logfile name as specified
  --d DIRECTORY_NAME, --directory DIRECTORY_NAME
                        Output directory name as specified
  --version             show program's version number and exit

Program flow

  1. readmic: Read input micrograph

  2. getline: Get line coordinates from micrograph

  3. fitcube: Fit extracted coordinates to cubic function

  4. visfit: Visualize extracted line and fitted function