टेंसरफ़्लो:: ऑप्स:: एनकोडजेपीईजी
#include <image_ops.h>एक छवि को JPEG-एन्कोड करें।
सारांश
 image एक 3-डी uint8 टेन्सर आकार [height, width, channels] है।
 एन्कोडेड आउटपुट के रंग प्रारूप को ओवरराइड करने के लिए attr format उपयोग किया जा सकता है। मान हो सकते हैं:
-  ``` : Use a default format based on the number of channels in the image. *ग्रेस्केल: Output a grayscale JPEG image. Theछवि का: Output a grayscale JPEG image. Thedimension ofmust be 1. *आरजीबी: Output an RGB JPEG image. Theछवि का: Output an RGB JPEG image. Thedimension of3 होना चाहिए।
 यदि format निर्दिष्ट नहीं है या खाली स्ट्रिंग है, तो image में चैनलों की संख्या के फ़ंक्शन में एक डिफ़ॉल्ट प्रारूप चुना जाता है:
- 1: एक ग्रेस्केल छवि आउटपुट करें ।
- 3: एक आरजीबी छवि आउटपुट करें ।
तर्क:
- स्कोप: एक स्कोप ऑब्जेक्ट
-  छवि: आकार [height, width, channels]के साथ 3-डी।
 वैकल्पिक विशेषताएँ (देखें Attrs ):
- प्रारूप: प्रति पिक्सेल छवि प्रारूप।
- गुणवत्ता: संपीड़न की गुणवत्ता 0 से 100 तक (उच्च बेहतर और धीमी है)।
- प्रगतिशील: यदि सत्य है, तो एक JPEG बनाएं जो उत्तरोत्तर (मोटे से बारीक) लोड हो।
- ऑप्टिमाइज़_साइज़: यदि सही है, तो बिना गुणवत्ता परिवर्तन के आकार को कम करने के लिए सीपीयू/रैम खर्च करें।
- chroma_downsampling: http://en.wikipedia.org/wiki/Chroma_subsampling देखें।
-  घनत्व_इकाई: x_densityऔरy_densityनिर्दिष्ट करने के लिए उपयोग की जाने वाली इकाई: पिक्सेल प्रति इंच ('in') या सेंटीमीटर ('cm')।
- x_घनत्व: प्रति घनत्व इकाई क्षैतिज पिक्सेल।
- y_घनत्व: प्रति घनत्व इकाई लंबवत पिक्सेल।
- xmp_metadata: यदि खाली नहीं है, तो इस XMP मेटाडेटा को छवि शीर्षलेख में एम्बेड करें।
रिटर्न:
-  Output: 0-डी. JPEG-एन्कोडेड छवि.
| निर्माता और विध्वंसक | |
|---|---|
| EncodeJpeg (const :: tensorflow::Scope & scope, :: tensorflow::Input image) | |
| EncodeJpeg (const :: tensorflow::Scope & scope, :: tensorflow::Input image, const EncodeJpeg::Attrs & attrs) | 
| सार्वजनिक गुण | |
|---|---|
| contents | |
| operation | |
| सार्वजनिक समारोह | |
|---|---|
| node () const | ::tensorflow::Node * | 
| operator::tensorflow::Input () const | |
| operator::tensorflow::Output () const | |
| सार्वजनिक स्थैतिक कार्य | |
|---|---|
| ChromaDownsampling (bool x) | |
| DensityUnit (StringPiece x) | |
| Format (StringPiece x) | |
| OptimizeSize (bool x) | |
| Progressive (bool x) | |
| Quality (int64 x) | |
| XDensity (int64 x) | |
| XmpMetadata (StringPiece x) | |
| YDensity (int64 x) | |
| संरचनाएँ | |
|---|---|
| टेंसरफ्लो:: ऑप्स:: एनकोडजेपीईजी:: एटर्स | EncodeJpeg के लिए वैकल्पिक विशेषता सेटर। | 
सार्वजनिक गुण
अंतर्वस्तु
::tensorflow::Output contents
संचालन
Operation operation
सार्वजनिक समारोह
एनकोडजेपीईजी
EncodeJpeg( const ::tensorflow::Scope & scope, ::tensorflow::Input image )
एनकोडजेपीईजी
EncodeJpeg( const ::tensorflow::Scope & scope, ::tensorflow::Input image, const EncodeJpeg::Attrs & attrs )
नोड
::tensorflow::Node * node() const
ऑपरेटर::टेन्सरफ़्लो::इनपुट
operator::tensorflow::Input() const
ऑपरेटर::टेन्सरफ़्लो::आउटपुट
operator::tensorflow::Output() const
सार्वजनिक स्थैतिक कार्य
क्रोमाडाउनसैंपलिंग
Attrs ChromaDownsampling( bool x )
घनत्व इकाई
Attrs DensityUnit( StringPiece x )
प्रारूप
Attrs Format( StringPiece x )
अनुकूलन आकार
Attrs OptimizeSize( bool x )
प्रगतिशील
Attrs Progressive( bool x )
गुणवत्ता
Attrs Quality( int64 x )
Xघनत्व
Attrs XDensity( int64 x )
XmpMetadata
Attrs XmpMetadata( StringPiece x )
Yघनत्व
Attrs YDensity( int64 x )