tensorflow/lite/g3doc/api_docs/java/org/tensorflow/lite/support/image/MlImageAdapter.html
public class MlImageAdapter
Converts MlImage to TensorImage and vice versa.
| static ColorSpaceType |
createColorSpaceTypeFrom(int imageFormat)
Creatas a ColorSpaceType from MlImage.ImageFormat.
|
| static TensorImage |
createTensorImageFrom(MlImage mlImage)
Creates a TensorImage from an MlImage.
|
From class java.lang.Object
| boolean | equals(Object arg0) | | final Class<?> | getClass() | | int | hashCode() | | final void | notify() | | final void | notifyAll() | | String | toString() | | final void | wait(long arg0, int arg1) | | final void | wait(long arg0) | | final void | wait() |
Creatas a ColorSpaceType from MlImage.ImageFormat.
| imageFormat | |
Creates a TensorImage from an MlImage.
IMPORTANT: The returned TensorImage shares storage with mlImage, so do not modify the contained object in the TensorImage, as MlImage expects its contained data are immutable. Also, callers should use MlImage#getInternal()#acquire() and MlImage#release() to avoid the mlImage being released unexpectedly.
| mlImage | |
| IllegalArgumentException | if the mlImage is built from an unsupported container. |