EagerSession.DevicePlacementPolicy
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
ควบคุมวิธีดำเนินการเมื่อเราพยายามเรียกใช้การดำเนินการบนอุปกรณ์ที่กำหนด แต่เทนเซอร์อินพุตบางตัวไม่อยู่ในอุปกรณ์นั้น
วิธีการสืบทอด
จากคลาส java.lang.Enum int สุดท้าย | |
ภายใน | เปรียบเทียบถึง (วัตถุ arg0) |
บูลีนสุดท้าย | เท่ากับ (วัตถุ arg0) |
คลาสสุดท้าย<E> | getDeclaringClass () |
int สุดท้าย | แฮชโค้ด () |
สตริงสุดท้าย | ชื่อ () |
int สุดท้าย | ลำดับ () |
สตริง | toString () |
คงที่ <T ขยาย Enum <T>> T | valueOf (คลาส <T> arg0, สตริง arg1) |
จากคลาส java.lang.Object บูลีน | เท่ากับ (วัตถุ arg0) |
คลาสสุดท้าย<?> | รับคลาส () |
ภายใน | แฮชโค้ด () |
โมฆะสุดท้าย | แจ้ง () |
โมฆะสุดท้าย | แจ้งทั้งหมด () |
สตริง | toString () |
โมฆะสุดท้าย | รอสักครู่ (ยาว arg0, int arg1) |
โมฆะสุดท้าย | รอ (ยาว arg0) |
โมฆะสุดท้าย | รอ () |
จากอินเทอร์เฟซ java.lang.Comparable บทคัดย่อ | CompareTo (E ขยาย Enum<E> arg0) |
ค่าแจงนับ
EagerSession.DevicePlacementPolicy สุดท้ายแบบคงที่สาธารณะ ชัดเจน
การรันการดำเนินการด้วยเทนเซอร์อินพุตบนอุปกรณ์ที่ไม่ถูกต้องจะล้มเหลว
EagerSession.DevicePlacementPolicy สาธารณะขั้นสุดท้ายแบบ คงที่เงียบ
คัดลอกเทนเซอร์อย่างเงียบๆ ซึ่งมีต้นทุนด้านประสิทธิภาพ เนื่องจากการดำเนินการจะถูกบล็อกจนกว่าการคัดลอกจะเสร็จสิ้น นี่คือนโยบายตำแหน่งเริ่มต้น
EagerSession.DevicePlacementPolicy สุดท้ายแบบคงที่สาธารณะ SILENT_FOR_INT32
นโยบายการจัดตำแหน่งซึ่งจะคัดลอกเทนเซอร์ int32 โดยไม่ต้องแจ้งให้ทราบ แต่ไม่ใช่ประเภทอื่นๆ
คำเตือน EagerSession.DevicePlacementPolicy สุดท้ายแบบคงที่สาธารณะ
คัดลอกเทนเซอร์ไปยังอุปกรณ์ที่ถูกต้องแต่บันทึกคำเตือน
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers ส่วน Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ เนื้อหาบางส่วนได้รับอนุญาตภายใต้ใบอนุญาต NumPy
อัปเดตล่าสุด 2025-07-28 UTC
[null,null,["อัปเดตล่าสุด 2025-07-28 UTC"],[],[],null,["# EagerSession.DevicePlacementPolicy\n\npublic static final enum **EagerSession.DevicePlacementPolicy** \nControls how to act when we try to run an operation on a given device but some input tensors\nare not on that device. \n\n### Inherited Methods\n\nFrom class java.lang.Enum \n\n|----------------------------------|--------------------------------------------------------------------------------------------------------------------------------------|\n| final int | compareTo([EagerSession.DevicePlacementPolicy](/versions/r2.8/api_docs/java/org/tensorflow/EagerSession.DevicePlacementPolicy) arg0) |\n| int | compareTo(Object arg0) |\n| final boolean | equals(Object arg0) |\n| final Class\\\u003cE\\\u003e | getDeclaringClass() |\n| final int | hashCode() |\n| final String | name() |\n| final int | ordinal() |\n| String | toString() |\n| static \\\u003cT extends Enum\\\u003cT\\\u003e\\\u003e T | valueOf(Class\\\u003cT\\\u003e arg0, String arg1) |\n\nFrom class java.lang.Object \n\n|------------------|---------------------------|\n| boolean | equals(Object arg0) |\n| final Class\\\u003c?\\\u003e | getClass() |\n| int | hashCode() |\n| final void | notify() |\n| final void | notifyAll() |\n| String | toString() |\n| final void | wait(long arg0, int arg1) |\n| final void | wait(long arg0) |\n| final void | wait() |\n\nFrom interface java.lang.Comparable \n\n|--------------|-------------------------------------|\n| abstract int | compareTo(E extends Enum\\\u003cE\\\u003e arg0) |\n\nEnum Values\n-----------\n\n#### public static final EagerSession.DevicePlacementPolicy\n**EXPLICIT**\n\nRunning operations with input tensors on the wrong device will fail. \n\n#### public static final EagerSession.DevicePlacementPolicy\n**SILENT**\n\nSilently copy the tensor, which has a performance cost since the operation will be blocked\ntill the copy completes. This is the default placement policy. \n\n#### public static final EagerSession.DevicePlacementPolicy\n**SILENT_FOR_INT32**\n\nPlacement policy which silently copies int32 tensors but not other dtypes. \n\n#### public static final EagerSession.DevicePlacementPolicy\n**WARN**\n\nCopy the tensor to the right device but log a warning."]]