A note to the developers

To add a new algorithm one has to do two things:

(a) Write a class that implements the ITrackingAlgorithm interface (javadoc here: http://homer.zpr.fer.hr/bactimas/doku.php?id=javadoc:javadoc).

These are the summaries of the requested methods:

  void beforeBatch(int firstFrameNo) 
           Invoked before processing batch.
  void beforeStep(int frameNo) 
           Invoked before every step().
  java.lang.String getAbbrev() 
           Algorihm name abbreviation, used for display in the frame tree.
  java.lang.String getClassName() 
           Class name, used for instantiation.
  java.lang.String getName() 
           A friendly name, to be shown to the user.
  void step(int frameNo, VPoint translation) 
           This is the main function to implement - the one that performs the tracking / segmentation.     

From within the these methods, primarily step() method, a develeoper has at his disposal the entire ImageJ library and several additional Bactimas methods, such as (from the CurrentExperiment class):

 ImagePlus getImagePlus(ImageStripType channel, int frameNo, String altFormat) 
    Returns the ImageJ's ImagePlus object for the given frameNo, channel and (not required) alternative image format (tif, jpg, ...) with png being default
 LinkedList<Bacteria> getBacteriasForFrame(int frameNo) getBacteriasForFrame(int frameNo)
    Returns the list of bacterias on the given frame.
 boolean saveROI(Roi roi, int frameNo, Bacteria b, int roiType) 
    Perists the (caluculated) roi for the bacteria b into the database.

Also, it is probably helpful to take a look at the implementation of proposed “Copy And Adjust” algorihtm in the class:

 bactimas.algorithms.CopyAndAdjustAlgorithm implements ITrackingAlgorithm 

(b) Append the full class name in the conf/all.algorithms file text file so that Bactimas can instantiate it at run time.


  • See the already available algorithms implementing the ITrackingAlgorithm interface.
  • Consult the JavaDoc for the details.
QR Code
QR Code gs (generated for current page)