Observed since 21 Oct, 11:04 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
AI job deployment templates with YAML and Jinja2.
Getting started.
pip install ai-jobdeploy
mkdir .jsTemplates must implement 5 fields: params, meta, config, values and builds.
params is a list of parameters specified on creation up of the resource.
meta is a list and subset of "subdir", "id", "project".
config is a dictionary of configured values (e.g. security group ids, etc..)
values are a dictionary of formatted values (on the basis of parameters) which are
and may be referred to in the builds.
The builds section must implement up and down. There are 3 types of builds:
sequencescriptfilesequence: sequence of scripts or files.
script: an executable script (usually bash).
file: a file saved to the path given by the build name.
local.yaml
params:
- name
- run
meta:
- id
- subdir
- project
config:
python: /usr/bin/python3
builds:
install:
type: script
content: |
#!/bin/bash
{{ params['python'] }} -m pip install -r requirements.txt
deploy_script:
type: file
content: |
#!/bin/bash
mkdir -p checkpoints/{{ params.name }}
{{ params['run'] }} | tee checkpoints/{{ params.name }}/log
start:
type: script
content: |
#!/bin/bash
chmod +x .jd/{{ params['subdir'] }}/tasks/deploy_script
tmux new-session -d -s {{ params['project'] }}-{{ params['id'] }} ".jd/{{ params['subdir'] }}/tasks/deploy_script"
watch:
type: script
content: |
#!/bin/bash
tmux a -t {{ params['project'] }}-{{ params['id'] }}
down:
type: script
whitelist: [256]
content: |
#!/bin/bash
tmux kill-session -t {{ params['project'] }}-{{ params['id'] }}
purge:
type: script
content: |
#!/bin/bash
rm -rf checkpoints/{{ params['name'] }}
up:
type: sequence
content:
- install
- deploy_script
- start
List resources:
jd ls
Here is how to create the my_model.yaml resource:
jd build local up --params run='python3 -u test.py',name=test
Do something with the resource (anything apart from up). Get id from jd ls.
jd build watch --id <id>
Stop resource:
jd rm <id> [--purge/--no-purge]
Download counts and popularity will appear here as the collector receives them.
| Version | Published | Direct dependencies | Open version |
|---|---|---|---|
| 0.0.1.dev19 | 27 Jun 2022 | 0 |
This describes our collected data; it is not a security assessment.
Observed since 21 Oct, 11:04 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package:7e035bc3e1fdcca388ba606e14560b85b6e4de601436ae94d757eabb9968b439