开始训练作业时出现 AWS Sagemaker PermissionError?

时间:2021-06-20 08:05:25

标签: amazon-web-services tensorflow amazon-sagemaker aws-deeplens

我正在关注 AWS DeepLens 文档:Build and Run the Head Pose Detection Project,并在 Train a Head Pose Detection Model in SageMaker 部分遇到问题,特别是运行 estimator.fit(dataset_location) 来启动训练作业。

These are the code cells that I've run,这是我收到的错误:PermissionError: [Errno 13] Permission denied: '/home/ec2-user/SageMaker/lost+found'

老实说,我不确定 lost+found 文件夹是什么。它似乎是 Jupyter Notebook 实例中的一个隐藏文件夹。我在 YouTube 的视频教程中看到过它,但在我的目录中没有看到它;但是,它确实存在,因为当我尝试创建名为“lost+found”的新文件夹时,出现此错误:An error occurred while renaming "Untitled Folder" to "lost+found". File already exists: lost+found

get_execution_role() 返回正确的角色,具有以下权限:

  • AmazonSageMakerFullAccess
  • IAM – GetRole、GetRolePolicy、PassRole
  • S3 – ListBucket、GetObject、PutObject、DeleteObject

我还尝试升级到 Tensorflow 2 和 Python 3.6,而不是原来的 TF 1.4 和 Python 2.7(本教程是在 2018 年编写的),但仍然遇到相同的错误。我的 IAM 帐户已被授予管理员权限,因此这也不应该是问题。其他人似乎没有这个问题,我到处搜索,所以我不知道还有什么可以尝试的。

非常感谢社区的投入,谢谢!

1 个答案:

答案 0 :(得分:0)

发现问题 - 我无法看到“lost+found”文件夹(即隐藏),因为我没有正确的权限。

修复:在 Jupyter 笔记本中,运行 !sudo chmod 777 lost+found