Class ImageParser2D
- All Implemented Interfaces:
Runnable,org.scijava.Cancelable,org.scijava.command.Command,org.scijava.Contextual,org.scijava.plugin.SciJavaPlugin,Parser,ProfileProperties
- Author:
- Tiago Ferreira
-
Field Summary
FieldsModifier and TypeFieldDescriptionfinal intstatic final intFlag for integration of repeated measures: averagestatic final intFlag for integration of repeated measures: medianstatic final intFlag for integration of repeated measures: modeFields inherited from class sc.fiji.snt.analysis.sholl.parsers.ImageParser
cal, center, channel, frame, imp, lowerT, maxX, maxY, maxZ, minX, minY, minZ, profile, properties, radii, running, start, statusService, upperT, voxelSize, xc, yc, zcFields inherited from interface sc.fiji.snt.analysis.sholl.ProfileProperties
HEMI_EAST, HEMI_NONE, HEMI_NORTH, HEMI_SOUTH, HEMI_WEST, INTG_MEAN, INTG_MEDIAN, INTG_MODE, KEY_2D3D, KEY_CALIBRATION, KEY_CENTER, KEY_CHANNEL_POS, KEY_EFFECTIVE_STEP_SIZE, KEY_EXTRA_MEASUREMENT, KEY_FRAME_POS, KEY_HEMISHELLS, KEY_ID, KEY_NSAMPLES, KEY_NSAMPLES_INTG, KEY_SLICE_POS, KEY_SOURCE, KEY_THRESHOLD_RANGE, SRC_IMG, SRC_TABLE, SRC_TRACES, UNSET -
Constructor Summary
ConstructorsConstructorDescriptionImageParser2D(ij.ImagePlus imp) ImageParser2D(ij.ImagePlus imp, org.scijava.Context context) -
Method Summary
Modifier and TypeMethodDescriptionGets the Sholl profile generated by the parsing operation.voidparse()Performs the parsing operation to extract the Sholl profile.voidsetAggressiveSpikeSuppression(boolean enabled) Sets experimental spike suppression mode.voidsetCenter(double x, double y) voidsetCenterPx(int x, int y) voidsetPosition(int channel, int slice, int frame) voidsetRadii(double startRadius, double step, double endRadius) voidsetRadii(double startRadius, double step, double endRadius, int span, int integrationFlag) voidsetRadiiSpan(int nSamples, int integrationFlag) Methods inherited from class sc.fiji.snt.analysis.sholl.parsers.ImageParser
checkUnsetFields, checkUnsetFields, clearStatus, getCircumferencePoints, getIsotropicVoxelSize, getMask, getMaskProcessor, isRetrieveIntDensitiesSet, maxPossibleRadius, reset, run, setCenter, setCenterFromROI, setCenterFromROI, setCenterPx, setHemiShells, setPosition, setRadii, setRetrieveIntDensities, setThreshold, successful, terminate, withinBounds, withinThreshold, withinXYbounds, withinZboundsMethods inherited from class org.scijava.command.ContextCommand
cancel, getCancelReason, isCanceledMethods inherited from class org.scijava.AbstractContextual
context, getContextMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.scijava.Contextual
setContext
-
Field Details
-
MEAN
public static final int MEANFlag for integration of repeated measures: average- See Also:
-
MEDIAN
public static final int MEDIANFlag for integration of repeated measures: median- See Also:
-
MODE
public static final int MODEFlag for integration of repeated measures: mode- See Also:
-
MAX_N_SPANS
public final int MAX_N_SPANS- See Also:
-
-
Constructor Details
-
ImageParser2D
public ImageParser2D(ij.ImagePlus imp) -
ImageParser2D
public ImageParser2D(ij.ImagePlus imp, org.scijava.Context context)
-
-
Method Details
-
setCenterPx
public void setCenterPx(int x, int y) -
setCenter
public void setCenter(double x, double y) -
setAggressiveSpikeSuppression
public void setAggressiveSpikeSuppression(boolean enabled) Sets experimental spike suppression mode.When sampling binarized images, jagged (ladder-like) foreground edges can produce single-pixel "spikes" that go tangent to the sampling shell, registering as spurious intersections. This is not an algorithmic problem with Sholl analysis itself: it is an inherent consequence of rasterized circles intersecting rasterized structures.
By default, (off), SNT uses legacy stair-aware suppression that only removes isolated ring hits matching specific diagonal staircase patterns in the source image. This is the same behavior as v4.x and is safe for all image types including skeletonized (1-pixel wide) structures.
When enabled, SNT applies a stricter 1D morphological opening on the ring: any foreground pixel whose immediate ring neighbors are both background is suppressed. This effectively removes single-pixel noise but will also suppress genuine intersections where a thin neurite crosses the sampling shell at a steep angle, producing exactly one foreground pixel on the ring. Do not use with skeletonized images.
- Parameters:
enabled- if true, applies aggressive 1D ring suppression (suitable for thick processes only). If false (default), uses legacy stair-aware suppression compatible with all image types.
-
setRadii
public void setRadii(double startRadius, double step, double endRadius) - Overrides:
setRadiiin classImageParser
-
setRadii
public void setRadii(double startRadius, double step, double endRadius, int span, int integrationFlag) -
setRadiiSpan
public void setRadiiSpan(int nSamples, int integrationFlag) -
getProfile
Description copied from interface:ParserGets the Sholl profile generated by the parsing operation.This method returns the profile containing intersection counts at various radial distances. The profile should only be retrieved after calling
Parser.parse()and verifying success withParser.successful().- Specified by:
getProfilein interfaceParser- Overrides:
getProfilein classImageParser- Returns:
- the Sholl profile, or null if parsing has not been performed or was unsuccessful
-
parse
public void parse()Description copied from interface:ParserPerforms the parsing operation to extract the Sholl profile.This method analyzes the data source and computes intersection counts at various radial distances from the center point. The resulting profile can be retrieved using
Parser.getProfile().Implementations should handle any necessary preprocessing, validation, and error handling during the parsing process.
- Specified by:
parsein interfaceParser- Overrides:
parsein classImageParser
-
setPosition
public void setPosition(int channel, int slice, int frame)
-