public static enum EagerSession.DevicePlacementPolicy extends Enum<EagerSession.DevicePlacementPolicy>
Enum Constant and Description |
---|
EXPLICIT
Running operations with input tensors on the wrong device will fail.
|
SILENT
Silently copy the tensor, which has a performance cost since the operation will be blocked
till the copy completes.
|
SILENT_FOR_INT32
Placement policy which silently copies int32 tensors but not other dtypes.
|
WARN
Copy the tensor to the right device but log a warning.
|
Modifier and Type | Method and Description |
---|---|
static EagerSession.DevicePlacementPolicy |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static EagerSession.DevicePlacementPolicy[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final EagerSession.DevicePlacementPolicy EXPLICIT
public static final EagerSession.DevicePlacementPolicy WARN
public static final EagerSession.DevicePlacementPolicy SILENT
public static final EagerSession.DevicePlacementPolicy SILENT_FOR_INT32
public static EagerSession.DevicePlacementPolicy[] values()
for (EagerSession.DevicePlacementPolicy c : EagerSession.DevicePlacementPolicy.values()) System.out.println(c);
public static EagerSession.DevicePlacementPolicy valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullCopyright © 2022. All rights reserved.