Class ObjectMeasurements

java.lang.Object
qupath.lib.analysis.features.ObjectMeasurements

public class ObjectMeasurements extends Object
Experimental class to generate object measurements.

May very well be moved, removed or refactored in a future release...

Author:
Pete Bankhead
  • Constructor Details

    • ObjectMeasurements

      public ObjectMeasurements()
  • Method Details

    • addShapeMeasurements

      public static void addShapeMeasurements(PathObject pathObject, PixelCalibration cal, ObjectMeasurements.ShapeFeatures... features)
      Add shape measurements for one object. If this is a cell, measurements will be made for both the nucleus and cell boundary where possible.
      Parameters:
      pathObject - the object for which measurements should be added
      cal - pixel calibration, used to determine units and scaling
      features - specific features to add; if empty, all available shape features will be added
    • addShapeMeasurements

      public static void addShapeMeasurements(Collection<? extends PathObject> pathObjects, PixelCalibration cal, ObjectMeasurements.ShapeFeatures... features)
      Add shape measurements for multiple objects. If any of these objects is a cell, measurements will be made for both the nucleus and cell boundary where possible.
      Parameters:
      pathObjects - the objects for which measurements should be added
      cal - pixel calibration, used to determine units and scaling
      features - specific features to add; if empty, all available shape features will be added
    • addIntensityMeasurements

      public static void addIntensityMeasurements(ImageServer<BufferedImage> server, PathObject pathObject, double downsample, Collection<ObjectMeasurements.Measurements> measurements, Collection<ObjectMeasurements.Compartments> compartments) throws IOException
      Measure all channels of an image for one individual object or cell. All compartments are measured where possible (nucleus, cytoplasm, membrane and full cell).

      Note: This implementation is likely to change in the future, to enable neighboring cells to be measured more efficiently.

      Parameters:
      server - the server containing the pixels (and channels) to be measured
      pathObject - the cell to measure (the MeasurementList will be updated)
      downsample - resolution at which to request pixels
      measurements - requested measurements to make
      compartments - the cell compartments to measure; ignored if the object is not a cell
      Throws:
      IOException