forked from Azure/azureml-examples
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Batch notebooks update for txt2img to address environment error (Azur…
…e#2953) * Pass custom environment in batch txt2img notebooks * cli example * cli update * code quality --------- Co-authored-by: grajguru <[email protected]>
- Loading branch information
1 parent
a5c29c3
commit 581112f
Showing
13 changed files
with
737 additions
and
18 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
...thon/foundation-models/system/inference/text-to-image/scoring-files/docker_env/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
FROM mcr.microsoft.com/azureml/openmpi4.1.0-ubuntu20.04:20230620.v1 | ||
|
||
ENV CONDA_ENVIRONMENT_PATH /azureml-envs/text-to-image | ||
|
||
# Prepend path to AzureML conda environment | ||
ENV PATH $CONDA_ENVIRONMENT_PATH/bin:$PATH | ||
|
||
# Create conda environment | ||
COPY conda_dependencies.yaml . | ||
RUN conda env create -p $CONDA_ENVIRONMENT_PATH -f conda_dependencies.yaml -q && \ | ||
rm conda_dependencies.yaml && \ | ||
conda run -p $CONDA_ENVIRONMENT_PATH pip cache purge && \ | ||
conda clean -a -y | ||
|
||
RUN pip freeze | ||
|
||
# This is needed for mpi to locate libpython | ||
ENV LD_LIBRARY_PATH $CONDA_ENVIRONMENT_PATH/lib:$LD_LIBRARY_PATH |
19 changes: 19 additions & 0 deletions
19
...on-models/system/inference/text-to-image/scoring-files/docker_env/conda_dependencies.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
channels: | ||
- conda-forge | ||
dependencies: | ||
- python=3.8.16 | ||
- pip<=23.1.2 | ||
- pip: | ||
- mlflow==2.3.2 | ||
- torch==1.13.0 | ||
- transformers==4.29.1 | ||
- diffusers==0.23.0 | ||
- accelerate==0.22.0 | ||
- azureml-core==1.52.0 | ||
- azureml-mlflow==1.52.0 | ||
- azure-ai-contentsafety==1.0.0b1 | ||
- aiolimiter==1.1.0 | ||
- azure-ai-mlmonitoring==0.1.0a3 | ||
- azure-mgmt-cognitiveservices==13.4.0 | ||
- azure-identity==1.13.0 | ||
name: mlflow-env |
1 change: 1 addition & 0 deletions
1
...models/system/inference/text-to-image/scoring-files/score/parallel_run_step.settings.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"append_row": {"pandas.DataFrame.to_csv": {"sep": ",","index": true}}} |
Oops, something went wrong.