address comments
This commit is contained in:
parent
9ece30ba7c
commit
75178dbafb
@ -305,18 +305,18 @@ TF_ImportGraphDefOptionsSetValidateColocationConstraints(
|
|||||||
TF_ImportGraphDefOptions* opts, unsigned char enable);
|
TF_ImportGraphDefOptions* opts, unsigned char enable);
|
||||||
|
|
||||||
// Load the library specified by library_filename and register the pluggable
|
// Load the library specified by library_filename and register the pluggable
|
||||||
// device and related kernels present in that library. This function should work
|
// device and related kernels present in that library. This function is not
|
||||||
// on all the platforms supported by TensorFlow, apart from embedded/mobile
|
// supported on embedded on mobile and embedded platforms and will fail if
|
||||||
// platforms.
|
// called.
|
||||||
//
|
//
|
||||||
// Pass "library_filename" to a platform-specific mechanism for dynamically
|
// Pass "library_filename" to a platform-specific mechanism for dynamically
|
||||||
// loading a library. The rules for determining the exact location of the
|
// loading a library. The rules for determining the exact location of the
|
||||||
// library are platform-specific and are not documented here.
|
// library are platform-specific and are not documented here.
|
||||||
//
|
//
|
||||||
// On success, place OK in status and return the newly created library handle.
|
// On success, returns the newly created library handle and places OK in status.
|
||||||
// The caller owns the library handle.
|
// The caller owns the library handle.
|
||||||
//
|
//
|
||||||
// On failure, return nullptr and places an error status in status.
|
// On failure, returns nullptr and places an error status in status.
|
||||||
TF_CAPI_EXPORT extern TF_Library* TF_LoadPluggableDeviceLibrary(
|
TF_CAPI_EXPORT extern TF_Library* TF_LoadPluggableDeviceLibrary(
|
||||||
const char* library_filename, TF_Status* status);
|
const char* library_filename, TF_Status* status);
|
||||||
|
|
||||||
|
@ -1243,10 +1243,10 @@ class Context(object):
|
|||||||
self._thread_local_data.invoking_op_callbacks = value
|
self._thread_local_data.invoking_op_callbacks = value
|
||||||
|
|
||||||
def _initialize_physical_devices(self, reinitialize=False):
|
def _initialize_physical_devices(self, reinitialize=False):
|
||||||
"""Get local devices visible to the system.
|
"""Gets local devices visible to the system.
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
reinitialize: This flag will reinitialize self._physical_devices so that
|
reinitialize: If True, reinitializes self._physical_devices so that
|
||||||
dynamic registered devices will also be visible to the python front-end.
|
dynamic registered devices will also be visible to the python front-end.
|
||||||
"""
|
"""
|
||||||
# We lazy initialize self._physical_devices since we do not want to do this
|
# We lazy initialize self._physical_devices since we do not want to do this
|
||||||
@ -1272,7 +1272,7 @@ class Context(object):
|
|||||||
self._import_config()
|
self._import_config()
|
||||||
|
|
||||||
def reinitialize_physical_devices(self):
|
def reinitialize_physical_devices(self):
|
||||||
"""Get local devices visible to the system."""
|
"""Gets local devices visible to the system."""
|
||||||
# Reinitialize the physical device list after registering
|
# Reinitialize the physical device list after registering
|
||||||
# the pluggable device.
|
# the pluggable device.
|
||||||
self._initialize_physical_devices(True)
|
self._initialize_physical_devices(True)
|
||||||
|
Loading…
Reference in New Issue
Block a user