टेंसरफ़्लो :: ऑप्स :: स्पार्सक्रॉस
#include <sparse_ops.h>
विरल और घने टेनर्स की सूची से विरल क्रॉस उत्पन्न करता है।
सारांश
सेशन में दो सूचियाँ, 2 डी SparseTensor
से एक और 2 डी Tensor
एक लेता है, प्रत्येक में एक फीचर कॉलम की विशेषताएं होती हैं। यह इन विशेषताओं के SparseTensor
क्रॉस के साथ एक 2D SparseTensor
आउटपुट करता है।
उदाहरण के लिए, यदि इनपुट
inputs[0]: SparseTensor with shape = [2, 2] [0, 0]: "a" [1, 0]: "b" [1, 1]: "c" inputs[1]: SparseTensor with shape = [2, 1] [0, 0]: "d" [1, 0]: "e" inputs[2]: Tensor [["f"], ["g"]]हैं
फिर आउटपुट
shape = [2, 2] [0, 0]: "a_X_d_X_f" [1, 0]: "b_X_e_X_g" [1, 1]: "c_X_e_X_g"होगा
अगर hashed_output = true है तो आउटपुट
shape = [2, 2] [0, 0]: FingerprintCat64( Fingerprint64("f"), FingerprintCat64( Fingerprint64("d"), Fingerprint64("a"))) [1, 0]: FingerprintCat64( Fingerprint64("g"), FingerprintCat64( Fingerprint64("e"), Fingerprint64("b"))) [1, 1]: FingerprintCat64( Fingerprint64("g"), FingerprintCat64( Fingerprint64("e"), Fingerprint64("c")))होगा
तर्क:
- गुंजाइश: एक स्कोप ऑब्जेक्ट
- सूचकांक: 2-डी। प्रत्येक इनपुट
SparseTensor
। - मान: 1-डी। प्रत्येक
SparseTensor
मूल्य। - आकार: 1-डी। प्रत्येक
SparseTensor
आकृतियाँ। - dense_inputs: 2-डी। घने
Tensor
द्वारा प्रस्तुत कॉलम। - hashed_output: यदि सही है, तो स्ट्रिंग के बजाय क्रॉस का हैश लौटाता है। यह हमें स्ट्रिंग जोड़तोड़ से बचने की अनुमति देगा।
- num_buckets: यह प्रयोग किया जाता है अगर hashed_output सच है। output = hashed_valuenum_buckets अगर num_buckets> 0 और hashed_value।
- hash_key: hash_key निर्दिष्ट करें जिसका उपयोग
FingerprintCat64
64 फ़ंक्शन द्वारा क्रॉस उंगलियों के निशान को संयोजित करने के लिए किया जाएगा।
रिटर्न:
-
Output
output_indices: 2-D।SparseTensor
। -
Output
output_values: 1-D।SparseTensor
याSparseTensor
गैर-रिक्त मान। -
Output
output_shape: 1-D।SparseTensor
का आकार।
कंस्ट्रक्टर और डिस्ट्रक्टर्स | |
---|---|
SparseCross (const :: tensorflow::Scope & scope, :: tensorflow::InputList indices, :: tensorflow::InputList values, :: tensorflow::InputList shapes, :: tensorflow::InputList dense_inputs, bool hashed_output, int64 num_buckets, int64 hash_key, DataType out_type, DataType internal_type) |
सार्वजनिक विशेषताएँ | |
---|---|
operation | |
output_indices | |
output_shape | |
output_values |
सार्वजनिक विशेषताएँ
ऑपरेशन
Operation operation
output_indices
::tensorflow::Output output_indices
output_shape
::tensorflow::Output output_shape
output_values
::tensorflow::Output output_values
सार्वजनिक कार्य
स्पार्सक्रॉस
SparseCross( const ::tensorflow::Scope & scope, ::tensorflow::InputList indices, ::tensorflow::InputList values, ::tensorflow::InputList shapes, ::tensorflow::InputList dense_inputs, bool hashed_output, int64 num_buckets, int64 hash_key, DataType out_type, DataType internal_type )