Skip to Content

unblur.com & summovie.com

10 replies [Last post]
Ludo
Offline
Joined: 5 Jun 2015

Hi,

I wanted to give a go at unblur and summovie.
I'm unsure how to launch them on a folder full of mrc stacks?
I guess I should create a .com file very much like rmeasure is using but I'm not sure what it should contain.
Could you give me an example of how to do that?

Thank you,
Ludo

timgrant
Offline
Joined: 16 Jul 2010
Hi Ludo,You can write a

Hi Ludo,

You can write a script to run it, just like the .com file in rmeasure.

The number and order of arguments differs depending on which options you select, so your best bet would be to run it interactively using the parameters you want - then use that order to create the script.

For example the following will align "input_movie.mrc" which contains 100 frames, create an aligned sum called "aligned_sum.mrc", and a text file containing the shifts ("movie_shifts.txt") - a pixel size of 1A, with dose filtering set to YES, and thus an exposure per frame of 1.4e/A2 at 300kv. Expert options is set to NO. : -

#!/bin/csh
#
./unblur << eof
input_movie.mrc
100
aligned_sum.mrc
movie_shifts.txt
1
YES
1.4
300
NO
eof

Hope that helps!

Tim

Ludo
Offline
Joined: 5 Jun 2015
Thanks.That's what I needed.

Thanks.
That's what I needed.

I edited my unblur.com as this:

#!/bin/csh
#
./unblur << eof
$i
52
${i%.mrc}_sum.mrc
${i%.mrc}_shifts.txt
1.77
YES
1
300
NO
eof
#

but I can't start a loop on this.
foreach i (*.mrc); ./unblur.com; end
it doesn't work.
Sorry for being bad at this. I never had to run an interactive script like this.
How do I tell to run on all the mrc in the folder with these parameters.
Must sounds very basic to you ... THANKS!

timgrant
Offline
Joined: 16 Jul 2010
Hi Ludo,I think you are

Hi Ludo,

I think you are using bash format in your script and csh doesn't like it. You're probably better off sticking with bash - in which case the following script should achieve what you want in combination with *.mrc (assuming the only mrc files in the directory are movie frame stakcks):-

!/bin/bash
#
for i in "$@"
do
./unblur << eof
$i
52
${i%.mrc}_sum.mrc
${i%.mrc}_shifts.txt
1.77
YES
1
300
NO
eof
done

Thanks,

Tim

Ludo
Offline
Joined: 5 Jun 2015
Hi, Me again, If I do that

Hi,
Me again,
If I do that script, nothing happens.
If I replace "$@" by *.mrc then all the mrc files are read with the options but only the last one is aligned.

forrtl: severe (24): end-of-file during read, unit 5, file /proc/21416/fd/0

I get this forrtl error except for the last file of the folder that is being aligned fine.
a quick google tells me it's run out of data ...?

what did you mean by "in combination with *.mrc"?
Thanks.

timgrant
Offline
Joined: 16 Jul 2010
Hi Ludo, I meant if you save

Hi Ludo,

I meant if you save that script e.g. as unblur.com and then run :-

./unblur.com *.mrc

Can you try that and let me know if there are still problems.

Thanks

Ludo
Offline
Joined: 5 Jun 2015
seems to be working.

seems to be working.
Thanks very much for the help!

I have another question.
After running unblur, I can use the shifts file to run summovie.
Summovie also generates and average. I couldn't find a reference to summovie in the elife paper.
Did I miss it?

Thanks.

timgrant
Offline
Joined: 16 Jul 2010
Hi Ludo, Yes summovie

Hi Ludo,

Yes summovie essentially does the same thing as unblur, just without the alignment. It's included purely so you can try different options for the dose filter or make sums for different ranges of movie frames without re-running the alignment.

Not that it is a very important point - but in both cases the programs generate sums.

BertramDaum
Offline
Joined: 22 Nov 2017
Hi Tim, this may be a silly

Hi Tim,
this may be a silly question, I'm relatively new to the single particle field. Do I assume correctly that summovie uses the unaligned stacks as input files and then applies the alignment using the shift files generated by a previous unblur run?

Can I also run summovie on aligned stacks and if not, do you have a script at hand that can do that?

Many thanks,
B

timgrant
Offline
Joined: 16 Jul 2010
Yes, this is correct. The

Yes, this is correct.

The way summovie is setup, you need to provide a shift file, and these shifts are applied before summing. If you wanted to use an aligned stack, then you could always provide a shift file that was all 0.0. This would apply no shifts, and just sum the movie.

Cheers,

Tim

Ludo
Offline
Joined: 5 Jun 2015
ok great. Thanks again!

ok great.
Thanks again!