Link Search Menu Expand Document

DecodeBmp


tensorflow C++ API

tensorflow::ops::DecodeBmp

Decode the first frame of a BMP-encoded image to a uint8 tensor.


Summary

The attrchannelsindicates the desired number of color channels for the decoded image.

Accepted values are:

  • 0: Use the number of channels in the BMP-encoded image.
  • 3: output an RGB image.
  • 4: output an RGBA image.

Arguments:

  • scope: A Scope object
  • contents: 0-D. The BMP-encoded image.

Returns:

  • Output: 3-D with shape[height, width, channels]. RGB order

Constructor

  • DecodeBmp(const ::tensorflow::Scope & scope, ::tensorflow::Input contents, const DecodeBmp::Attrs & attrs) .

Public attributes

  • tensorflow::Output image.

DecodeBmp block

Source link : https://github.com/EXPNUNI/enuSpaceTensorflow/blob/master/enuSpaceTensorflow/tf_image_ops.cpp

Argument:

  • Scope scope : A Scope object (A scope is generated automatically each page. A scope is not connected.)
  • contents : connect Input node.
  • DecodeBmp::Attrs attrs : input attrs value. ex) channels_ = 0;

Return:

  • Output image: Output object of DecodeBmp class object.

Result:

  • std::vector(Tensor) product_result : Returned object of executed result by calling session.

Using Method