keystoneml.utils

VectorizedImage

trait VectorizedImage extends Image

Helper trait for implementing Images that wrap vectorized representations of images.

Linear Supertypes
Image, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. VectorizedImage
  2. Image
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def getInVector(vectorIdx: Int): Double

  2. abstract def imageToVectorCoords(x: Int, y: Int, channelIdx: Int): Int

  3. abstract val metadata: ImageMetadata

    Definition Classes
    Image
  4. abstract def putInVector(vectorIdx: Int, newVal: Double): Unit

  5. abstract def vectorToImageCoords(v: Int): Coordinate

Concrete Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. lazy val coord: Coordinate

    Attributes
    protected
  9. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  10. def equals(o: Any): Boolean

    An inefficient implementation of equals().

    An inefficient implementation of equals(). Subclasses should override this if they can implement it more cheaply and anyone cares about such things.

    Definition Classes
    Image → AnyRef → Any
  11. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  12. def flatSize: Int

    Definition Classes
    Image
  13. def get(x: Int, y: Int, channelIdx: Int): Double

    Get the pixel value at (x, y, channelIdx).

    Get the pixel value at (x, y, channelIdx). Channels are indexed as follows:

    • If the image is RGB, 0 => blue, 1 => green, 2 => red.
    • If the image is RGB+alpha, 0 => blue, 1=> green, 2 => red, and 3 => alpha.
    • Other channel schemes are unsupported; the only reason this matters is that input converters (e.g. from BufferedImage to Image) need to handle channels consistently.
    Definition Classes
    VectorizedImageImage
  14. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  15. def getSingleChannelAsFloatArray(): Array[Float]

    Definition Classes
    Image
  16. def getSingleChannelAsIntArray(): Array[Int]

    Definition Classes
    Image
  17. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  18. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  19. def iter(): Iterator[CoordinateValue]

    Returns an iterator of coordinate values based on the "natural" order of a Vectorized image.

    Returns an iterator of coordinate values based on the "natural" order of a Vectorized image. That is, this returns a value of the form (x,y,channel,value) in order.

    This method is optimized to avoid unnecessary memory allocation and designed to approach the performance of an equivalent while loop over the image pixels for speeding up things like Aggregation over an image regardless of underlying image ordering.

    An important restriction is that the reference to the returned CoordinateValue should not be modified or saved by the caller.

    returns

  20. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  21. final def notify(): Unit

    Definition Classes
    AnyRef
  22. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  23. def put(x: Int, y: Int, channelIdx: Int, newVal: Double): Unit

    Put a pixel value at (x, y, channelIdx).

    Put a pixel value at (x, y, channelIdx).

    Definition Classes
    VectorizedImageImage
  24. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  25. def toArray: Array[Double]

    Returns a flat version of the image, represented as a single array.

    Returns a flat version of the image, represented as a single array. It is indexed as follows: The pixel value for (x, y, channelIdx) is at channelIdx + x*numChannels + y*numChannels*xDim.

    This implementation works for arbitrary image formats but it is inefficient.

    Definition Classes
    Image
  26. def toString(): String

    Definition Classes
    AnyRef → Any
  27. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Image

Inherited from AnyRef

Inherited from Any

Ungrouped