This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
pipeline:utilities:sxrelion2sphire [2018/02/27 19:00] moriya |
pipeline:utilities:sxrelion2sphire [2018/08/22 12:02] fmerino |
||
---|---|---|---|
Line 2: | Line 2: | ||
===== sxrelion2sphire ===== | ===== sxrelion2sphire ===== | ||
- | RELION to SPHIRE Conversion: Create several types of parameter text files and a particle | + | RELION to SPHIRE Conversion: Create several types of parameter text files and per-micrograph virtual stacks of particle |
\\ | \\ | ||
Line 9: | Line 9: | ||
Usage in command line | Usage in command line | ||
- | sxrelion2sphire.py | + | sxrelion2sphire.py |
\\ | \\ | ||
Line 16: | Line 16: | ||
sxrelion2sphire does not support MPI. | sxrelion2sphire does not support MPI. | ||
- | sxrelion2sphire.py | + | sxrelion2sphire.py |
| | ||
- | sxrelion2sphire.py | + | sxrelion2sphire.py |
+ | |||
+ | sxrelion2sphire.py | ||
\\ | \\ | ||
===== Input ===== | ===== Input ===== | ||
=== Main Parameters === | === Main Parameters === | ||
- | ; input_star_file : Input RELION STAR file: Specify a STAR file generated by RELION. The file should contain parameters related to Micrographs, | + | ; input_star_file : Input RELION STAR file: Specify a STAR file generated by RELION. The file should contain parameters related to Micrographs, |
- | ; output_directory : Output directory: All the results will be written in here. This directory will be created automatically and it must not exist previously. (default required string) | + | ; output_directory : Output directory: All the results will be written in here. It cannot |
+ | ; %%--%%relion_project_dir : RELION project directory: Path to RELION project directory associated with the RELION STAR file. By default, the program assume the current directory is the RELION project directory. (default none) | ||
; %%--%%star_section : Section title in STAR file: The section title in the RELION star file where the data should be extracted. (default data_) | ; %%--%%star_section : Section title in STAR file: The section title in the RELION star file where the data should be extracted. (default data_) | ||
- | ; %%--%%box_size : Box size: Box size for particle extraction. | + | |
- | ; %%--%%create_stack : Create | + | |
+ | ; %%--%%create_stack : Create | ||
\\ | \\ | ||
=== Advanced Parameters === | === Advanced Parameters === | ||
+ | ; %%--%%cs_save_as_hdf : Save stack as HDF file: Save a stack file in HDF file format instead in bdb format. In this case, the stack file will contain all particle images in the input RELION STAR file. Effective only with %%--%%create_stack. (default False) | ||
\\ | \\ | ||
Line 38: | Line 43: | ||
\\ | \\ | ||
=== List of Output Files === | === List of Output Files === | ||
+ | The program copies the subdirectory structure under the RELION project directory based on the information stored in the input RELION STAR file. | ||
+ | For example, if two sets of micrographs are stored in two different subdirectories (e.g. " | ||
+ | Each output subdirectory will contain the files in the table below. | ||
+ | |||
|| **File Name** || **Discription** || | || **File Name** || **Discription** || | ||
- | || sphire_micrographs.txt || Text file containing a list of micrograph names/paths (Micrograph selection file). It can be used as input of [[pipeline: | + | || *_micrographs.txt || Text file containing a list of micrograph names/paths (Micrograph selection file). It can be used as input of [[pipeline: |
- | || sphire_cter_partres.txt || Text file containing a list of CTF parameters in CTER format (CTER partres file). It can be used as an input of [[pipeline: | + | || *_cter_partres.txt || Text file containing a list of CTF parameters in CTER format (CTER partres file). It can be used as an input of [[pipeline: |
- | || sphire_stack_ctf.txt || Text file containing a list of CTF parameters. It can be used as an input of [[pipeline: | + | || Coordinates/ |
- | || Coordinates/ | + | || Rebox/*.rbx || SPHIRE rebox files. One for each micrograph. These files can be used as inputs |
- | || sphire_stack_proj3d.txt || Text file containing a list of 3D projection parameters. It can be used as an input of [[pipeline:utilities:sxheader|sxheader]] %%--%%params=xform.projection. (requires | + | || EMAN2DB/*_stack.bdb || Per-micrograph virtual stacks |
- | || sphire_stack_chunk*.txt || Text file containing a list of particle | + | || *_stack.hdf || Stack of all particle images in HDF format |
- | || sphire_stack.hdf || Particle image stack (only when %%--%%create_stack option is used) containing the header entries associated with the extracted information. (requires Particle Extraction Category) || | + | |
\\ | \\ | ||
===== Description ===== | ===== Description ===== | ||
- | Run the script to create several types of parameter text files and particle image stack in SPHIRE format from parameters stored in a RELION STAR file. The RELION STAR should contain entries related to Micrographs, | + | Run the script to create several types of parameter text files and particle image stack in SPHIRE format from parameters stored in a RELION STAR file. The RELION STAR should contain entries related to Micrographs, |
\\ | \\ | ||
Line 64: | Line 72: | ||
\\ | \\ | ||
=== Related Header Entries === | === Related Header Entries === | ||
- | The script | + | The script sets the following header entries of EMAN2DB/ |
|| **Header Entry** || **Discription** || | || **Header Entry** || **Discription** || | ||
|| ptcl_source_relion || RELION' | || ptcl_source_relion || RELION' | ||
|| ptcl_source_image || Micrograph path (relative path) where RELION extracted this particle image. || | || ptcl_source_image || Micrograph path (relative path) where RELION extracted this particle image. || | ||
- | || ptcl_source_coord || Coordinates of this particle in the Micrograph in sphire | + | || ptcl_source_coord || Coordinates of this particle in the Micrograph in SPHIRE |
|| ptcl_source_coord_id || Coordinates ID in the original coordinate file RELION used. || | || ptcl_source_coord_id || Coordinates ID in the original coordinate file RELION used. || | ||
|| data_n || Serial particle image ID. Here, it is same as ptcl_source_coord_id. || | || data_n || Serial particle image ID. Here, it is same as ptcl_source_coord_id. || | ||
Line 76: | Line 84: | ||
|| ptcl_source_apix || Pixel size of the associated micrograph. || | || ptcl_source_apix || Pixel size of the associated micrograph. || | ||
|| xform.projection || 3D projection parameters. || | || xform.projection || 3D projection parameters. || | ||
+ | || relion_max_prob_dist || Maximum probability distribution value computed by RELION. || | ||
+ | || relion_norm_correct || Normalisation correction value computed by RELION. || | ||
|| chunk_id || Chunk ID (or Subset ID) where this particle belongs. || | || chunk_id || Chunk ID (or Subset ID) where this particle belongs. || | ||
Line 85: | Line 95: | ||
\\ | \\ | ||
==== Reference ==== | ==== Reference ==== | ||
+ | |||
+ | \\ | ||
+ | ==== Developer Notes ==== | ||
+ | === 2018/07/11 Toshio Moriya === | ||
+ | - Change default stack format from HDF to bdb (%%--%%cs_save_as_hdf). | ||
+ | * By default, the script creates a local particle image stack for each micrograph like sxwindow.py. | ||
+ | * Likewise, because of synchronisation problem of subprocess execution, user must run particle stack command to create a virtual stack of all particles. | ||
+ | - Accept arbitrary output file name (%%--%%outputs_root). | ||
+ | |||
+ | - Added SPHIRE rebox file output support. The rebox file contains box coordinates, | ||
+ | * This modification solves the problem associated with per-particle defocus estimation. | ||
+ | |||
+ | - Add relion project directory option so that the script can be run from any directory (%%--%%relion_project_dir). | ||
+ | * That is, you don't anymore need to make sure the current directory is the project folder of the RELION (where you run RELION GUI). | ||
+ | * The program appends the path of relion project directory to micrograph path extracted from the star file. | ||
+ | |||
+ | These changes require user not to break the relative path whenever they move or copy the micrographs because sxrelion2sparx.py use full name including the path stored in the input RELION STAR file. | ||
+ | |||
+ | The program does not generate the following output files anymore. | ||
+ | |||
+ | || **File Name** || **Discription** || | ||
+ | || sphire_stack_ctf.txt || Text file containing a list of CTF parameters. It can be used as an input of [[pipeline: | ||
+ | || sphire_stack_proj3d.txt || Text file containing a list of 3D projection parameters. It can be used as an input of [[pipeline: | ||
+ | || sphire_stack_chunk*.txt || Text file containing a list of particle IDs for the subset (#0 and #1). It can be used as an input of [[pipeline: | ||
+ | |||
+ | To create these files, please use [[pipeline: | ||
\\ | \\ | ||
Line 100: | Line 136: | ||
\\ | \\ | ||
==== See also ==== | ==== See also ==== | ||
- | [[pipeline:window:sxwindow|sxwindow]], [[pipeline: | + | [[pipeline:cter:sxcter|sxcter]], [[pipeline: |
\\ | \\ |