You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/machine-learning/how-to-troubleshoot-environments.md
+54-2Lines changed: 54 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -841,8 +841,60 @@ You must specify a base Docker image for the environment, and the conda environm
841
841
* See [how to set a conda specification on the environment definition](https://aka.ms/azureml/environment/set-conda-spec-on-environment-definition)
842
842
843
843
### Invalid conda dependencies
844
-
- Make sure the conda dependencies specified in your conda specification are formatted correctly
845
-
- See [how to create a conda file manually](https://aka.ms/azureml/environment/how-to-create-conda-file)
844
+
<!--issueDescription-->
845
+
**Potential causes:**
846
+
* The conda dependencies specified in your environment definition aren't formatted correctly
847
+
848
+
**Affected areas (symptoms):**
849
+
* Failure in registering your environment
850
+
<!--/issueDescription-->
851
+
852
+
**Troubleshooting steps**
853
+
854
+
*Applies to: Python SDK v1*
855
+
856
+
Ensure that `conda_dependencies` is a JSONified version of the conda dependencies YAML structure
857
+
858
+
```json
859
+
"condaDependencies": {
860
+
"channels": [
861
+
"anaconda",
862
+
"conda-forge"
863
+
],
864
+
"dependencies": [
865
+
"python=3.8",
866
+
{
867
+
"pip": [
868
+
"azureml-defaults"
869
+
]
870
+
}
871
+
],
872
+
"name": "project_environment"
873
+
}
874
+
```
875
+
876
+
Conda dependencies can also be specified using the `add_conda_package` method
877
+
878
+
```python
879
+
from azureml.core.environment import CondaDependencies
880
+
881
+
env = Environment(name="env")
882
+
conda_dep = CondaDependencies()
883
+
conda_dep.add_conda_package("python==3.8")
884
+
env.python.conda_dependencies=conda_dep
885
+
```
886
+
887
+
*Applies to: Azure CLI & Python SDK v2*
888
+
889
+
You must specify a base Docker image for the environment, and the conda environment will be built on top of that image
890
+
* Provide the relative path to the conda file
891
+
* See how to [create an environment from a conda specification](https://aka.ms/azureml/environment/create-env-conda-spec-v2)
892
+
893
+
**Resources**
894
+
* See [more extensive examples](https://github.com/Azure/MachineLearningNotebooks/blob/9b1e130d18d3c61d41dc225488a4575904897c85/how-to-use-azureml/training/using-environments/using-environments.ipynb)
895
+
* See [how to create a conda file manually](https://aka.ms/azureml/environment/how-to-create-conda-file)
896
+
* See [CondaDependencies class](https://aka.ms/azureml/environment/conda-dependencies-class)
897
+
* See [how to set a conda specification on the environment definition](https://aka.ms/azureml/environment/set-conda-spec-on-environment-definition)
846
898
847
899
### Missing conda channels
848
900
- If no conda channels are specified, conda will use defaults that might change
0 commit comments