What value should I set for directory_path for the Amazon SageMaker SDK with FSx as data source?

1

What value should I set for the directory_path parameter in FileSystemInput for the Amazon SageMaker SDK?

Here is some information about my Amazon FSx for Lustre file system:

  • My FSx ID is fs-0684xxxxxxxxxxx.
  • My FSx has the mount name lhskdbmv.
  • The FSx maps to an Amazon S3 bucket with files (without extra prefixes in their keys)

My attempts to describe the job and the results are the following:

Attempt 1:

fs = FileSystemInput(
    file_system_id='fs-0684xxxxxxxxxxx',
    file_system_type='FSxLustre',
    directory_path='lhskdbmv',
    file_system_access_mode='ro')

Result:

estimator.fit(fs) returns ClientError: An error occurred (ValidationException) when calling the CreateTrainingJob operation: FileSystem DirectoryPath 'lhskdbmv' for channel 'training' is not absolute or normalized. Please ensure you don't have a trailing "/", and/or "..", ".", "//" in the path.

Attempt 2:

fs = FileSystemInput(
    file_system_id='fs-0684xxxxxxxxxxx',
    file_system_type='FSxLustre',
    directory_path='/',
    file_system_access_mode='ro')

Result:

ClientError: An error occurred (ValidationException) when calling the CreateTrainingJob operation: The directory path for FSx Lustre file system fs-068406952bf758bac is invalid. The directory path must begin with mount name of the file system.

Attempt 3:

fs = FileSystemInput(
    file_system_id='fs-0684xxxxxxxxxxx',
    file_system_type='FSxLustre',
    directory_path='fsx',
    file_system_access_mode='ro')

Result:

ClientError: An error occurred (ValidationException) when calling the CreateTrainingJob operation: FileSystem DirectoryPath 'fsx' for channel 'training' is not absolute or normalized. Please ensure you don't have a trailing "/", and/or "..", ".", "//" in the path.

AWS
EXPERTE
gefragt vor 3 Jahren627 Aufrufe
1 Antwort
0
Akzeptierte Antwort

The directory_path parameter must point to /mountname/path/to/specific/folder/in-file-system. The value of mountname is returned in the CreateFileSystem API operation response. It is also returned in the response of the describe-file-systems AWS Command Line Interface (AWS CLI) command and the DescribeFileSystems API operation.

For your use case, the response might look similar to the following: mountName = lhskdbmv

beantwortet vor 3 Jahren

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen