@Namespace(value="tensorflow::ops") @NoOffset @Properties(inherit=tensorflow.class) public class DecodeJpeg extends Pointer
channels
indicates the desired number of color channels for the
decoded image.
Accepted values are:
* 0: Use the number of channels in the JPEG-encoded image.
* 1: output a grayscale image.
* 3: output an RGB image.
If needed, the JPEG-encoded image is transformed to match the requested number
of color channels.
The attr ratio
allows downscaling the image by an integer factor during
decoding. Allowed values are: 1, 2, 4, and 8. This is much faster than
downscaling the image later.
This op also supports decoding PNGs and non-animated GIFs since the interface is
the same, though it is cleaner to use tf.image.decode_image
.
Arguments:
* scope: A Scope object
* contents: 0-D. The JPEG-encoded image.
Optional attributes (see Attrs
):
* channels: Number of color channels for the decoded image.
* ratio: Downscaling ratio.
* fancy_upscaling: If true use a slower but nicer upscaling of the
chroma planes (yuv420/422 only).
* try_recover_truncated: If true try to recover an image from truncated input.
* acceptable_fraction: The minimum required fraction of lines before a truncated
input is accepted.
* dct_method: string specifying a hint about the algorithm used for
decompression. Defaults to "" which maps to a system-specific
default. Currently valid values are ["INTEGER_FAST",
"INTEGER_ACCURATE"]. The hint may be ignored (e.g., the internal
jpeg library changes to a version that does not have that specific
option.)
Returns:
* Output
: 3-D with shape [height, width, channels]
..Modifier and Type | Class and Description |
---|---|
static class |
DecodeJpeg.Attrs
Optional attribute setters for DecodeJpeg
|
Pointer.CustomDeallocator, Pointer.Deallocator, Pointer.NativeDeallocator, Pointer.ReferenceCounter
Constructor and Description |
---|
DecodeJpeg(Pointer p)
Pointer cast constructor.
|
DecodeJpeg(Scope scope,
Input contents) |
DecodeJpeg(Scope scope,
Input contents,
DecodeJpeg.Attrs attrs) |
Modifier and Type | Method and Description |
---|---|
static DecodeJpeg.Attrs |
AcceptableFraction(float x) |
Input |
asInput() |
Output |
asOutput() |
static DecodeJpeg.Attrs |
Channels(long x) |
static DecodeJpeg.Attrs |
DctMethod(BytePointer x) |
static DecodeJpeg.Attrs |
DctMethod(String x) |
static DecodeJpeg.Attrs |
FancyUpscaling(boolean x) |
Output |
image() |
DecodeJpeg |
image(Output setter) |
Node |
node() |
Operation |
operation() |
DecodeJpeg |
operation(Operation setter) |
static DecodeJpeg.Attrs |
Ratio(long x) |
static DecodeJpeg.Attrs |
TryRecoverTruncated(boolean x) |
address, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, getDirectBufferAddress, getPointer, getPointer, getPointer, getPointer, hashCode, interruptDeallocatorThread, isNull, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetAddress, offsetof, offsetof, parseBytes, physicalBytes, physicalBytesInaccurate, position, position, put, realloc, referenceCount, releaseReference, retainReference, setNull, sizeof, sizeof, toString, totalBytes, totalCount, totalPhysicalBytes, withDeallocator, zero
public DecodeJpeg(Pointer p)
Pointer(Pointer)
.public Node node()
@ByVal public static DecodeJpeg.Attrs Channels(@Cast(value="tensorflow::int64") long x)
@ByVal public static DecodeJpeg.Attrs Ratio(@Cast(value="tensorflow::int64") long x)
@ByVal public static DecodeJpeg.Attrs FancyUpscaling(@Cast(value="bool") boolean x)
@ByVal public static DecodeJpeg.Attrs TryRecoverTruncated(@Cast(value="bool") boolean x)
@ByVal public static DecodeJpeg.Attrs AcceptableFraction(float x)
@ByVal public static DecodeJpeg.Attrs DctMethod(@tensorflow.StringPiece BytePointer x)
@ByVal public static DecodeJpeg.Attrs DctMethod(@tensorflow.StringPiece String x)
public DecodeJpeg operation(Operation setter)
public DecodeJpeg image(Output setter)
Copyright © 2022. All rights reserved.