Ray.jl
Ray.Ray
— ModuleRay
This package provides user-facing interface for Julia-on-Ray.
Ray.RayError
— TypeRayError <: Exception
Abstract super type of all Ray exception types.
Ray.RaySystemError
— TypeRaySystemError <: RayError
Indicates that Ray encountered a system error.
This exception is thrown when:
- The raylet is killed.
- Deserialization of a
ObjectRef
contains an unknown metadata error type.
Ray.RayTaskError
— TypeRayTaskError <: RayError
Indicates that a Ray task threw an exception during execution.
If a Ray task throws an exception during execution, a RayTaskError
is stored for the Ray task's output. When the object is retrieved, the contained exception is detected and thrown thereby propogating the exception to the Ray task caller.
Non-exported functions and types
Ray.GLOBAL_STATE_ACCESSOR
— Constantconst GLOBAL_STATE_ACCESSOR::Ref{ray_jll.GlobalStateAccessor}
Global binding for GCS client interface to access global state information. Currently only used to get the next job ID.
This is set during init
and used there to get the Job ID for the driver.
Ray.OutOfMemoryError
— TypeOutOfMemoryError <: RayError
Indicates that the node is running out of memory and is close to full.
This exception is thrown when the node is low on memory and tasks or actors are being evicted to free up memory.
Base.isready
— MethodBase.isready(obj_ref::ObjectRef)
Check whether obj_ref
has a value that's ready to be retrieved.
Base.wait
— MethodBase.wait(obj_ref::ObjectRef) -> Nothing
Block until isready(obj_ref)
.
Ray.get
— MethodRay.get(obj_ref::ObjectRef)
Retrieves the data associated with the object reference from the object store. This method is blocking until the data is available in the local object store.
If the task that generated the ObjectRef
failed with a Julia exception, the captured exception will be thrown on get
.
Ray.get_all_reference_counts
— Methodget_all_reference_counts()
For testing/debugging purposes, returns a Dict{ray_jll.ObjectID,Tuple{Int,Int}}
containing the reference counts for each object ID that the local raylet knows about. The first count is the "local reference" count, and the second is the count of submitted tasks depending on the object.
Ray.get_job_id
— Methodget_job_id() -> UInt32
Get the current job ID for this worker or driver. Job ID is the id of your Ray drivers that create tasks.
Ray.get_task_id
— Methodget_task_id() -> String
Get the current task ID for this worker in hex format.
Ray.put
— MethodRay.put(data) -> ObjectRef
Store data
in the object store. Returns an object reference which can used to retrieve the data
with Ray.get
.