Biowulf at the NIH
RSS Feed
3B on Biowulf
Bayesian analysis of blinking and bleaching, or 3B microscopy, is a method which analyses data in which many overlapping fluorophores undergo bleaching and blinking events, giving the structure at enhanced resolution. By using a Hidden Markov Model (HMM), it allows useful information to be obtained from data that would be impossible to analyse with standard localisation analysis techniques.

3B was developed in the Cox lab at Kings College London.

Important Note: 3B requires some libraries that are only installed on the Biowulf computational nodes at present. Thus, you will not be able to run a 3B job on the Biowulf login node.

Running a single 3B batch job on Biowulf

Set up a batch script along the following lines. This sample script uses the sample data provided with the program, which is available in /usr/local/apps/3B/1.1/test_data.tar.gz . The file multispot5.cfg can be copied from the same directory.

#PBS -N threeB
# this script is called 3Btest.bat

cd /data/username/mydir
tar xvzf /usr/local/apps/3B/1.1/test_data.tar.gz

# set up the environment for 3B
module load 3B

# copy the config file
cp $THREEBDIR/multispot5.cfg .

multispot5_headless --save_spots test_data/results.txt --log_ratios test_data/markup1.bmp test_data/img_000000*

Submit this job with:

biowulf% qsub -l nodes=1 3Btest.bat
This will submit the job to a node with at least 1 GB of memory. If more than 1GB of memory is required for this job, then you can specify the type of node on the qsub command line. e.g. if this job would require 6 GB of memory, submit to the next-highest node type with:
biowulf% qsub -l nodes=1:g8 3Btest.bat
Use 'freen' to see available node types.

Submitting a swarm of 3B jobs

Set up a swarm command file along the following lines. This assumes that a copy of multispot5.cfg exists in each directory.

cd /data/user/mydir/dat1; multispot5_headless --save_spots results1.txt --log_ratios markup1.bmp img_000000*
cd /data/user/mydir/dat2; multispot5_headless --save_spots results2.txt --log_ratios markup2.bmp img_000000*
cd /data/user/mydir/dat3; multispot5_headless --save_spots results3.txt --log_ratios markup3.bmp img_000000*
Submit this swarm with:
swarm -g 3 -f swarmfile --module 3B
The flag '-g 3' tells swarm that each command (a single line in the swarm command file) will require 3 GB of memory. Adjust this number as needed. (1 GB is the default)

Running a 3B job interactively

It is sometimes convenient to run a job interactively for debugging purposes. Allocate an interactive node and run the program on the command line as shown in the following sample session.

biowulf% qsub -I -l nodes=1:g8
qsub: waiting for job 4756051.biobos to start
qsub: job 4756051.biobos ready

[susanc@p1483 ]$ cd /data/susanc/3B/test_data
[susanc@p1483 test_data]$ module load 3B
[susanc@p1483 test_data]$ cp $THREEBDIR/multispot5.cfg .
[susanc@p1483 test_data]$ multispot5_headless --save_spots test_data/results.txt --log_ratios test_data/markup1.bmp test_data/img_000000*
The mean should be small compared to std:
mean = -0.000287303
std  = 0.0164858
mean = -0.0174273
std  = 1
Limit vector: 7.9846 0.5 0.5 0.5 


Modifying the model
Adding a spot
Original model: 1
Optimizing spot for model selection
Attempt 0 of 10
Eigenvalues are: -196.352 -22.7974 -9.39298 -3.79057 
Done optimizing for model selection
Hessien Eigenvalues are: 3.87157 10.8511 23.2741 199.614 
Model 2:
Energy: -32431.1
Occam: -2.41507
Position: -5.3033
Prob: -32438.8
Prob: -32449.2
Models evaluated
Keeping model 2
Model changed!

Modifying the model
Removing a spot
Original model: 2
Optimizing spot for model selection
Attempt 0 of 10
Eigenvalues are: -116.152 -9.32637 -3.0771 0.785446 
Grad = 0.0285123 0.594596 0.296756 -0.0358159 
Direction: 0
Direction: 1
Direction: 2
Direction: 3
Direction: 0
Direction: 1
Direction: 2
Direction: 3
Attempt 1 of 10
Eigenvalues are: -116.163 -9.3329 -3.11352 0.795662 
Grad = 0.0284963 0.594222 0.298653 -0.0356275 
Direction: 0
Direction: 1
Direction: 2
Direction: 3
Direction: 0
Direction: 1
Direction: 2
Direction: 3
Attempt 2 of 10
Eigenvalues are: -116.178 -9.34744 -3.11147 0.805675 
Grad = 0.0284862 0.594376 0.298631 -0.0361804 
Direction: 0
Direction: 1
Direction: 2
Direction: 3
Direction: 0
Direction: 1

[susanc@p1483 test_data]$ exit
Job 756051.biobos completed



3B online manual at the Cox lab website.

A set of scripts developed by Victor Wang and Peter Winter for the Biowulf cluster.