tensorflow::ops::Multinomial
#include <random_ops.h>สุ่มตัวอย่างจาก1การแจกแจงแบบพหุนาม
สรุป
ข้อโต้แย้ง:
- ขอบเขต: วัตถุ ขอบเขต
- logits: เทนเซอร์ 2 มิติที่มีรูปร่าง
[batch_size, num_classes]แต่ละส่วน[i, :]แสดงถึงค่าความน่าจะเป็นลอการิทึมที่ยังไม่ได้ปรับค่ามาตรฐานสำหรับทุกคลาส - num_samples: 0-D จำนวนตัวอย่างอิสระที่จะสุ่มสำหรับแต่ละส่วนของแถว
คุณลักษณะเสริม (ดูที่ Attrs ):
- seed: หาก seed หรือ seed2 ตัวใดตัวหนึ่งถูกตั้งค่าเป็นค่าที่ไม่ใช่ศูนย์ ตัวสร้างเลขสุ่มภายในจะใช้ seed ที่กำหนดให้ มิฉะนั้น จะใช้ seed แบบสุ่ม
- seed2: เมล็ดพันธุ์ที่สองเพื่อหลีกเลี่ยงการชนกันของเมล็ดพันธุ์
การส่งคืนสินค้า:
-
Output: เทนเซอร์ 2 มิติที่มีรูปร่าง[batch_size, num_samples]แต่ละส่วน[i, :]ประกอบด้วยป้ายกำกับคลาสที่วาดขึ้นโดยมีช่วง[0, num_classes)
ตัวสร้างและตัวทำลาย | |
|---|---|
Multinomial (const :: tensorflow::Scope & scope, :: tensorflow::Input logits, :: tensorflow::Input num_samples) | |
Multinomial (const :: tensorflow::Scope & scope, :: tensorflow::Input logits, :: tensorflow::Input num_samples, const Multinomial::Attrs & attrs) |
คุณลักษณะสาธารณะ | |
|---|---|
operation | |
output | |
หน้าที่สาธารณะ | |
|---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const | |
ฟังก์ชันคงที่สาธารณะ | |
|---|---|
OutputDtype (DataType x) | |
Seed (int64 x) | |
Seed2 (int64 x) | |
โครงสร้าง | |
|---|---|
| tensorflow::ops::Multinomial::Attrs | ตัวเลือกการตั้งค่าแอตทริบิวต์สำหรับ Multinomial |
คุณลักษณะสาธารณะ
การดำเนินการ
Operation operation
เอาต์พุต
::tensorflow::Output output
หน้าที่สาธารณะ
มัลติโนเมียล
Multinomial( const ::tensorflow::Scope & scope, ::tensorflow::Input logits, ::tensorflow::Input num_samples )
มัลติโนเมียล
Multinomial( const ::tensorflow::Scope & scope, ::tensorflow::Input logits, ::tensorflow::Input num_samples, const Multinomial::Attrs & attrs )
โหนด
::tensorflow::Node * node() const
ตัวดำเนินการ::เทนเซอร์โฟลว์::อินพุต
operator::tensorflow::Input() const
ตัวดำเนินการ::เทนเซอร์โฟลว์::เอาต์พุต
operator::tensorflow::Output() const
ฟังก์ชันคงที่สาธารณะ
เอาต์พุตประเภท
Attrs OutputDtype( DataType x )
เมล็ดพันธุ์
Attrs Seed( int64 x )
เมล็ดพันธุ์2
Attrs Seed2( int64 x )