LaunchAgent
2 minute read
Launch agent class which polls run given run queues and launches runs for wandb launch.
Arguments | |
---|---|
api |
Api object to use for making requests to the backend. |
config |
Config dictionary for the agent. |
Attributes | |
---|---|
num_running_jobs |
Return the number of jobs not including schedulers. |
num_running_schedulers |
Return just the number of schedulers. |
thread_ids |
Returns a list of keys running thread ids for the agent. |
Methods
check_sweep_state
Check the state of a sweep before launching a run for the sweep.
fail_run_queue_item
finish_thread_id
Removes the job from our list for now.
get_job_and_queue
initialized
Return whether the agent is initialized.
loop
Loop infinitely to poll for jobs and run them.
Raises | |
---|---|
KeyboardInterrupt |
if the agent is requested to stop. |
name
Return the name of the agent.
pop_from_queue
Pops an item off the runqueue to run as a job.
Arguments | |
---|---|
queue |
Queue to pop from. |
Returns | |
---|---|
Item popped off the queue. |
Raises | |
---|---|
Exception |
if there is an error popping from the queue. |
print_status
Prints the current status of the agent.
run_job
Set up project and run the job.
Arguments | |
---|---|
job |
Job to run. |
task_run_job
update_status
Update the status of the agent.
Arguments | |
---|---|
status |
Status to update the agent to. |
Feedback
Was this page helpful?
Glad to hear it! If you have further feedback, please let us know.
Sorry to hear that. Please tell us how we can improve.