Show / Hide Table of Contents

Class ImageUtil

Inheritance
System.Object
Keras
Base
ImageUtil
Implements
System.IDisposable
Inherited Members
Base.Parameters
Base.None
Base.Init()
Base.ToPython()
Base.InvokeStaticMethod(Object, String, Dictionary<String, Object>)
Base.InvokeMethod(String, Dictionary<String, Object>)
Base.Item[String]
Keras.Instance
Keras.keras
Keras.keras2onnx
Keras.tfjs
Keras.Dispose()
Keras.ToTuple(Array)
Keras.ToList(Array)
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Keras.PreProcessing.Image
Assembly: Keras.dll
Syntax
public class ImageUtil : Base, IDisposable

Methods

| Improve this Doc View Source

ArrayToImg(NDarray, String, Boolean, String)

Array to img.

Declaration
public static dynamic ArrayToImg(NDarray x, string data_format = "", bool scale = true, string dtype = "")
Parameters
Type Name Description
Numpy.NDarray x

The x.

System.String data_format

The data format.

System.Boolean scale

if set to true [scale].

System.String dtype

The dtype.

Returns
Type Description
System.Object
| Improve this Doc View Source

DecodePredictions(NDarray, Int32)

Decodes the predictions.

Declaration
public static ImageNetPrediction[] DecodePredictions(NDarray preds, int top = 3)
Parameters
Type Name Description
Numpy.NDarray preds

The preds.

System.Int32 top

The top.

Returns
Type Description
ImageNetPrediction[]
| Improve this Doc View Source

ImageToArray(Object, String, String)

Images to array.

Declaration
public static NDarray ImageToArray(dynamic image, string data_format = "", string dtype = "")
Parameters
Type Name Description
System.Object image

The image.

System.String data_format

The data format.

System.String dtype

The dtype.

Returns
Type Description
Numpy.NDarray
| Improve this Doc View Source

LoadImg(String, String, Shape, String)

Loads the img.

Declaration
public static dynamic LoadImg(string path, string color_mode = "rgb", Shape target_size = null, string interpolation = "nearest")
Parameters
Type Name Description
System.String path

The path.

System.String color_mode

The color mode.

Shape target_size

Size of the target.

System.String interpolation

The interpolation.

Returns
Type Description
System.Object
| Improve this Doc View Source

PreprocessInput(NDarray, String, String)

Preprocesses the input.

Declaration
public static NDarray PreprocessInput(NDarray x, string data_format = "channels_last", string mode = "caffe")
Parameters
Type Name Description
Numpy.NDarray x

The input tensor.

System.String data_format
System.String mode
Returns
Type Description
Numpy.NDarray

Implements

System.IDisposable
  • Improve this Doc
  • View Source
Back to top Generated by DocFX