aws-samples / amazon-sagemaker-tensorflow-object-detection-api

Train and deploy models using TensorFlow 2 with the Object Detection API on Amazon SageMaker
MIT No Attribution
42 stars 34 forks source link

Error pushing docker image to ECR #23

Closed Abd-elr4hman closed 2 years ago

Abd-elr4hman commented 2 years ago

when i try running the cell !sh ./docker/build_and_push.sh $image_name in the train_model.ipynb i get the following output

Login Succeeded
Building image with name tf2-object-detection

then the image build starts and eventually i get this output

Pushing image to ECR ************dkr.ecr.ca-central-1.amazonaws.com/tf2-object-detection:20220615212708
The push refers to repository [************.dkr.ecr.ca-central-1.amazonaws.com/tf2-object-detection]

3a1f859c: Preparing 
2b66dc26: Preparing 
9ed25f44: Preparing 
1e49b945: Preparing 
e78a5581: Preparing 
066f4938: Preparing 
3c39552d: Preparing 
8a0e5cb3: Preparing 
25a2c8be: Preparing 
98774c15: Preparing 
ac5aed31: Preparing 
968f8782: Preparing 
3182417e: Preparing 
754e7e9d: Preparing 
1dbc2540: Preparing 
2da56dca: Preparing 
4f8ace47: Preparing 
226ba457: Preparing 
520b6c94: Preparing 
e4bf63c6: Preparing 
5c215047: Preparing 
52e3a18b: Preparing 
aa2fa9fe: Preparing 
325cc380: Preparing 
dd81f9fa: Preparing 
a1f859c: Retrying in 1 second   [24ARetrying in 8 seconds EOF

and no in the tf2-object-detection ECR repository

sofianhamiti commented 2 years ago

Hi @Abd-elr4hman, i have updated the repo with new TF version. Can you have a try and confirm it works now?

Abd-elr4hman commented 2 years ago

Hi @SofianHamiti, Thank you for your answer!

the issue was Permissions policies for AWS IAM role, after adding AmazonEC2ContainerRegistryFullAccess policy to my role I was able to push the docker image to ECR. Now it works fine.

Thank you for updating the repo!