Orchestration with Airflow
Make ML pipelines a breeze with Airflow and Anyscale
An Airflow DAG using the Ray Provider

Last updated
Was this helpful?
Make ML pipelines a breeze with Airflow and Anyscale

Last updated
Was this helpful?
Was this helpful?
import anyscale
anyscale.connect()
# ... now everything below runs on your Anyscale Ray cloud!
from ray_provider.decorators import ray_task
default_args = {
'on_success_callback': RayBackend.on_success_callback,
'on_failure_callback': RayBackend.on_failure_callback,
.
.
.
}
task_args = {"ray_conn_id": "ray_cluster_connection"}
.
.
.
@dag(
default_args=default_args,
.
.
)
def ray_example_dag():
@ray_task(**task_args)
def sum_cols(df: pd.DataFrame) -> pd.DataFrame:
return pd.DataFrame(df.sum()).T