Using ParallelRunConfig and DockerConfig not working

オープン
#1,979 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
30/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
azure, docker, jupyter-notebook, python

調査の方向性

リンクされている並列実行用 notebook から始め、そこにある ParallelRunConfig、DockerConfiguration、source_directory の設定を、提供されたスニペットと比較します。path/to/docker/script_1.py と init および run スクリプトを追跡し、イメージ内のファイルをどのように見つけているかを確認します。パイプラインの実行時に、スクリプトが想定される Hydra 構成を確実に見つけられれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Hello, I am attempting to use the ParallelRunStep for a set of python scripts that I currently run inside a docker container. I am trying to deploy this using an AzureML pipeline that reads from the docker image saved in our ACR. However, the init and run scripts in my parallel script never seem to be able to access the files I have moved into the docker container. Particularly when I try and search for a hydra config file in my init and run scripts, I am unable to find the file, even when I look for it explicitly. I have included a snippet that is based on the example code from this repo: example of parallel run config

Any idea what I am doing wrong? I have included a snippet of what I am trying below


docker_config = DockerConfiguration(use_docker=True, arguments=docker_args)
 
environment_name = "my-environment"
environment = Environment(environment_name)
base_image_name = os.getenv("ACR_BASE_IMAGE_NAME")
base_image_tag = os.getenv("ACR_IMAGE_TAG")
environment.docker.base_image = f"{base_image_name}:{base_image_tag}"

environment.docker.base_image_registry.address = f"{acr_name}.azurecr.io"

environment.docker.base_image_registry.username = os.getenv("ACR_USER")
environment.docker.base_image_registry.password = os.getenv("ACR_PASSWORD")
environment.python.user_managed_dependencies = True
environment.docker.enabled=True

run_config = RunConfiguration()
run_config.environment = environment
run_config.docker = docker_config

parallel_run_config = ParallelRunConfig(
        source_directory=".",
        entry_script="path/to/docker/script_1.py",  
        compute_target=compute_target,
        environment=environment,
        node_count=2,
        error_threshold=10,
        output_action="append_row",
        mini_batch_size=1,
        logging_level='DEBUG'
        )
step_parallel = ParallelRunStep(
        name="parallel-step",
        parallel_run_config=parallel_run_config,
        inputs=my_inputs,
        output=output_dir,
        arguments=args,                                   
        allow_reuse=True,
    )
    
step_parallel._runconfig.docker = docker_config #Tried with and without, does not seem to make a difference

pipeline_steps = StepSequence(steps=[step_parallel])
pipeline_run = Pipeline(workspace=ws, steps=pipeline_steps)

# Submit your pipeline run
submitted_pipeline_run = Experiment(ws, "Azure Pipeline").submit(pipeline_run, regenerate_outputs=True)```
主要言語
Jupyter Notebook
スター
4.5k
フォーク
2.6k
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

Azure/MachineLearningNotebooks のほかの issue

Azure/MachineLearningNotebooks の issue をすべて見る

似ている issue

DevOps の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。