public class Constrictor extends Object
This procedure is aware of possible overlapping and try to counteract them.
Constructor and Description |
---|
Constrictor()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
constrict(Snake snake,
ij.process.ImageProcessor ip)
Compute force power and moves nodes by predefined step.
|
boolean |
constrictWrite(Snake snake,
ij.process.ImageProcessor ip)
Deprecated.
Strictly related to absolute paths on disk. Probably for testing only.
|
void |
freezeProxSnakes(Nest nest,
int frame)
Freeze snakes which are close to each other in nest.
|
void |
implode(Nest nest,
int f)
Implode nest.
|
void |
loosen(Nest nest,
int frame)
Expand all snakes while preventing overlaps adequately to blowup parameter.
|
public boolean constrict(Snake snake, ij.process.ImageProcessor ip)
This routine should be called in loop. Each call moves nodes by
BOAState.BOAp.delta_t
.
snake
- Processed snakeip
- Original imageBOA_.tightenSnake(com.github.celldynamics.quimp.Snake)
public boolean constrictWrite(Snake snake, ij.process.ImageProcessor ip)
snake
- snakeip
- ippublic void loosen(Nest nest, int frame) throws BoaException
Dead snakes are ignored. Count snakes on frame.
This method blows up live snakes (e.g. from previous frame) and prepare for contracting at
current one next frame. snakes are expanded in small steps and at every step their nodes are
tested for proximity BOAState.BOAp.proxFreeze
. Only snakes whose centroids are closer
than BOAState.BOAp.proximity
are tested for overlapping. Note that this actions happen
before contracting snakes around objects. This is preparatory step and if we assume contracting
direction (BOAState.SegParam.contractingDirection
is true) so then after this step
snakes will not overlap during actual segmentation
constrict(Snake, ImageProcessor)
nest
- nestframe
- frameBoaException
- on snake scalepublic void freezeProxSnakes(Nest nest, int frame) throws BoaException
nest
- nest to process.frame
- current frameBoaException
- on errorpublic void implode(Nest nest, int f) throws BoaException
nest
- nestf
- frame numberBoaException
- on snake.implodeBOAState.SegParam.expandSnake
Copyright © 2002–2019 Department of Computer Science, Warwick University. All rights reserved.