How to import cryosparc particle coordinates in relion 3.1?

Hi,

Is there a new script available to convert .cs file after 2D classification to move to Relion3.1 ?
I tried csparc2star.py to convert particle.cs after 2D to convert onto relion 3.0 star file as recommended.
I tried to use relion_convert_star on the converted file (after changing @extract path info). However, it failed badly. Does this mean something is missing during conversion ?
Relion 3.0 format after conversion from cryosparc (python3 csparc2star.py particles_selected.cs particles_selected_350Box.star --boxsize 350):
data_optics

      loop_

     _rlnOpticsGroup #1

    _rlnImageSize #2

    _rlnImagePixelSize #3

    _rlnImageDimensionality #4

    1 450 0.820000 2

    data_particles

    loop_

    _rlnImageName #1

    _rlnAnglePsi #2

    _rlnOriginXAngst #3

    _rlnOriginYAngst #4

    _rlnPhaseShift #5

    _rlnRandomSubset #6

    _rlnClassNumber #7

   _rlnOpticsGroup #8

        000001@/media//P35/J88/extract/FoilHole_16507588_Da//extract/FoilHole_16507588_Data_16530972_16530974_20201116_172041_aligned_DW_particles.mrc 95.510201 2.741143 0.000000 0 1 58 1

Now if I try to convert this converted star file to relion 3.1 star file (relion_convert_star --i particles_selected_350Box.star --o particles_selected_350Box_rel3.1.star --Cs 2.7 --Q0 0.1), what I get is:

# version 30001

data_optics

loop_
_rlnOpticsGroup #1
_rlnOpticsGroupName #2
           1 opticsGroup1


# version 30001

data_micrographs

loop_
_rlnOpticsGroup #1
_rlnImageSize #2
_rlnImagePixelSize #3
_rlnImageDimensionality #4
           1          450     0.820000            2

Even the Relion 3.0 conversion looks like a lot pf parameters are missing. Please point out if I’m doing something wrong.

Thank you.

you need to add *_passthrough_particles.cs when doing conversion which contains additional metadata, e.g.:
csparc2star.py cryosparc_P14_J338_006_particles.cs P14_J334_passthrough_particles.cs P14_J338-2.star [–micrograph-path MotionCorr/OG1/Fractions/ --swapxy]
in [] are additional options

After that you also need to edit the resulting star file ( there was a post on the forum about it), e.g.:

  1. sed -i ‘s/_particles.mrc/_particles.mrcs/g’ P14_J207_noRSCN.star
  • you need to create links such that CS extracted particles have .mrcs extension

To point to the extract location (I prefer to do create a dir/ in relion project, e.g. CSextract/J207, to make it more concise)
2. sed -i ‘s/J207/extract/CSextract/J207/g’ P14_J207_noRSCN.star

Similarly for the movies (unless you did motion correction already in relion 3.1)
3. sed -i ‘s/J159/imported/MotionCorr/OG1/Fractions/g’ P14_J207_noRSCN.star

  1. Once you imported relion3 ‘star’ file you need to remove using relion_star_handler (if you have them):
    _rlnRandomSubset #17
    _rlnClassNumber #18

or you can do it before step #1 using relion_star_handler from relion < version 3.1

3 Likes

Thank you so much such elaborate explanation.
I just have one more query.
When we convert and import coordinate file to relion does it also carries all the CTF information and other calculations performed in CS ?

Yes, it does. Though if you want to also do polishing you need RELION 3.1 formatted star file after motion correction.
Moreover, in case of tilted data I would strongly recommend using PATCH CTF.

As per your advise I converted the particles from CS to relion 3.0 format. After that, I used relion’s version converter to convert the .star file from 3.0 to the Relion 3.1.
2D classification with the converted particles looks fine with Relion 3.1, however, internal features are still vague. Hopefully I’m nothing doing wrong so far.

The second thing is, using the converted particles I could not run an extraction job in relion-3.1 (I was hoping to downsample the particles while doing 2D classification).

if you can’t do extract, i assume you have not done motion correction in RELION (3.1).
If you would continue with relion, you need to use motioncorr wrapper (either v3.0 or 3.1, the latter would be easier). If you have done it (which version you used?), you might need to re-link your resulting averages.

I have not done the motion correction at all. It is done by on the fly packages while collecting the data on microscope. I’m working with dose-weighted micrographs. I’m not sure how to relink classes to the micrograph. Could you please give some advise on that ?

RELION motioncorr wrapper creates a star file for each movie with metadata which you need if you do polishing or extract. What program did the pipeline use to create dose weighted averages ?

The pipeline I am using uses RELION 3.0 wrapper when running motion correction. It’s fairly easy then to convert to RELION 3.1 format. Obviously it’s even easier when one’s pipeline would run RELION 3.1