apache / apache/dolphinscheduler-sdk-python
[impv] Auto create the whole task workspace to make the task the same workspace when running locally and on the DolphinScheduler platform
- Lenguaje dominante
- Python
- Estrellas
- 71
- Forks
- 26
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
For example, If I have the workspace like this: https://github.com/pytorch/examples/tree/main/word_language_model

We can submit the task
```python
# [start workflow]
from pydolphinscheduler.core import Workflow
from pydolphinscheduler.core.resource import Resource, LocalResource
from pydolphinscheduler.tasks import Shell
with Workflow(
name="auto_resources_example",
) as workflow:
# [start use_exists_resources]
task_use_resource = Shell(
name="example",
command=f"python main.py --cuda",
auto_resource=True
)
# [end use_exists_resources]
workflow.run()
# [end workflow]
```
Then, all the files will be uploaded to the resource center.
And there is another best way to track the file version, If this is the git repository, we only record the git repository, version, and diff.
Then, we can reproduce the workspace in dolphinscheduler. (Inspired by ClearML)
So, After developing a project locally, we can directly submit it to DolphinScheduler and run it directly. Except for some inconsistent environment variables.
Guía de contribución
Línea de trabajo
Comienza con los puntos de entrada pydolphinscheduler.core.Workflow y tasks.Shell mostrados en el ejemplo, incluidos workflow.run() y auto_resource=True; el workspace de ejemplo es word_language_model con main.py. Determina cómo recibe actualmente los archivos el Resource Center y, después, define qué se necesita para que una versión de un workspace local o de un repositorio Git, y su diff, sean reproducibles en DolphinScheduler, teniendo en cuenta las variables de entorno inconsistentes.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- git, python
- Área
- backend, devops
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 35/100