Saltar al contenido

Can't view my custom images in Sagemaker JupyterLab and Shared spaces

0

Hello, I create Sagemaker domain and want to use shared space for my team with custom image. I build this image and push to ECR, after that attach it to the domain, but I can't see it nor on private space nor in shared. I also add via AWS API images using json file as it suggested , but and it is work if I write for JupyterLab the following part of config (and this works only for private space): "JupyterLabAppSettings": { "CustomImages": [ { "AppImageConfigName": "app-image-config-1709543896355", "ImageName": "baseimage", "ImageVersionNumber": 1 } ], "DefaultResourceSpec": { "InstanceType": "ml.t3.medium", "SageMakerImageArn": "arn:aws:sagemaker:us-east-1:xxxxx:image/baseimage", "SageMakerImageVersionAlias": "1", "SageMakerImageVersionArn": "arn:aws:sagemaker:us-east-1:xxxxx:image-version/baseimage/1" }, "LifecycleConfigArns": [ "arn:aws:sagemaker:us-east-1:xxxxx:studio-lifecycle-config/autostop1hour" ] }

And I don't know which app-image-config should be pasted. Also, isn't here more comfortable methods to attach to my spaces custom images??

preguntada hace 2 años878 visualizaciones
1 Respuesta
0

Hi,

I had a similar issue and solved it by adding the custom images to the DefaultSpaceSettings as well.

  1. Describe your domain to get the aws sagemaker describe-domain --domain-id <YOUR_DOMAIN_ID>. Here you should see your DefaultUserSettings containing your custom images.
  2. Add the custom image to the DefaultSpaceSettings as well as DefaultUserSettings.
  3. Update the domain with the new JSON aws sagemaker update-domain --domain-id <YOUR_DOMAIN_ID> --cli-input-json file://file.json

NOTE this only worked once I the aws-cli upgraded from 2.17.42 to 2.15.37

https://docs.aws.amazon.com/cli/latest/reference/sagemaker/update-domain.html https://awscli.amazonaws.com/v2/documentation/api/latest/reference/sagemaker/describe-domain.html

{
  "DefaultUserSettings": {
    "ExecutionRole": "arn:aws:iam::XYZ:role/YOUR_ROLE",
    "JupyterLabAppSettings": {
      "CustomImages": [
        {
          "ImageName": "r-base",
          "ImageVersionNumber": 1,
          "AppImageConfigName": "XYZ"
        }
      ],
      "LifecycleConfigArns": []
    }
  },

  "DefaultSpaceSettings": {
    "ExecutionRole": "arn:aws:iam::XYZ:role/YOUR_ROLE",
    "JupyterLabAppSettings": {
      "CustomImages": [
        {
          "ImageName": "r-base",
          "ImageVersionNumber": 1,
          "AppImageConfigName": "XYZ"
        }
      ]
    }
  }
}

respondido hace un año

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.