tensorflow:: ops:: DecodePng

#include <image_ops.h>

एक PNG-एनकोडेड इमेज को uint8 या uint16 टेंसर में डिकोड करें।

सारांश

एट्रीब्यूट channels डिकोड की गई छवि के लिए वांछित रंग चैनलों की संख्या को इंगित करता है।

स्वीकृत मान इस प्रकार हैं:

  • 0: पीएनजी-एनकोडेड छवि में चैनलों की संख्या का उपयोग करें।
  • 1: एक ग्रेस्केल छवि आउटपुट करें।
  • 3: एक RGB छवि आउटपुट करें।
  • 4: एक आरजीबीए छवि आउटपुट करें।

यदि आवश्यक हो, तो पीएनजी-एन्कोडेड छवि को अनुरोधित रंग चैनलों की संख्या से मेल खाने के लिए रूपांतरित किया जाता है।

यह ऑपरेशन जेपीईजी और गैर-एनिमेटेड जीआईएफ को डिकोड करने का भी समर्थन करता है क्योंकि इंटरफ़ेस समान है, हालांकि tf.image.decode_image का उपयोग करना अधिक स्वच्छ है।

तर्क:

  • स्कोप: एक स्कोप ऑब्जेक्ट
  • विषयवस्तु: 0-D. पीएनजी-एन्कोडेड छवि।

वैकल्पिक विशेषताएँ (देखें Attrs ):

  • चैनल: डिकोड की गई छवि के लिए रंग चैनलों की संख्या।

प्रतिफल:

  • Output : [height, width, channels] आकार के साथ 3-डी।

कंस्ट्रक्टर और डिस्ट्रक्टर

DecodePng (const :: tensorflow::Scope & scope, :: tensorflow::Input contents)
DecodePng (const :: tensorflow::Scope & scope, :: tensorflow::Input contents, const DecodePng::Attrs & attrs)

सार्वजनिक विशेषताएँ

image
operation

सार्वजनिक समारोह

node () const
::tensorflow::Node *
operator::tensorflow::Input () const
operator::tensorflow::Output () const

सार्वजनिक स्थैतिक फ़ंक्शन

Channels (int64 x)
Dtype (DataType x)

संरचनाएँ

टेन्सरफ्लो::ऑप्स::डिकोडपीएनजी::एट्रिब्यूट्स

DecodePng के लिए वैकल्पिक विशेषता निर्धारक।

सार्वजनिक विशेषताएँ

छवि

::tensorflow::Output image

संचालन

Operation operation

सार्वजनिक समारोह

DecodePng

 DecodePng(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input contents
)

DecodePng

 DecodePng(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input contents,
  const DecodePng::Attrs & attrs
)

नोड

::tensorflow::Node * node() const 

ऑपरेटर::टेन्सरफ्लो::इनपुट

 operator::tensorflow::Input() const 

ऑपरेटर::टेन्सरफ्लो::आउटपुट

 operator::tensorflow::Output() const 

सार्वजनिक स्थैतिक फ़ंक्शन

चैनल

Attrs Channels(
  int64 x
)

डीटाइप

Attrs Dtype(
  DataType x
)