ALIYUN::PAI::DatasetVersion は、データセットバージョンを作成するために使用されます。
構文
{
"Type": "ALIYUN::PAI::DatasetVersion",
"Properties": {
"DataSourceType": String, // データソースのタイプ
"DatasetId": String, // データセット ID
"Property": String, // データセットのプロパティ
"Uri": String, // URI 設定
"Description": String, // データセットバージョンの説明
"DataSize": Integer, // データセットファイルのサイズ
"DataCount": Integer, // データセットファイルの数
"Labels": List, // データセットバージョンのラベル
"Options": String, // 拡張フィールド
"SourceType": String, // データソースのタイプ
"SourceId": String // データソースの ID
}
}プロパティ
プロパティ | タイプ | 必須 | 編集可能 | 説明 | 制約 |
DataSourceType | String | はい | いいえ | データソースのストレージタイプ。 | 複数のストレージタイプはカンマ (,) で区切ります。有効な値:
説明 データセットバージョンの DataSourceType 値は、データセットの DataSourceType 値と同じである必要があります。データセットバージョンを作成すると、システムは値が同じかどうかを確認します。 |
DatasetId | String | はい | いいえ | データセットの ID。 | なし。 |
Property | String | はい | いいえ | データセットのプロパティ。 | 有効な値:
|
Uri | String | はい | いいえ | Uniform Resource Identifier (URI) の構成。 |
|
Description | String | いいえ | いいえ | データセットバージョンの説明。 | 説明を使用してデータセットバージョンを区別できます。 |
DataSize | Integer | いいえ | いいえ | データセットファイルのサイズ。 | 単位: バイト。 |
DataCount | Integer | いいえ | いいえ | データセットファイルの数。 | なし。 |
Labels | List | いいえ | いいえ | データセットバージョンのラベル。 | 詳細については、「ラベルのプロパティ」をご参照ください。 |
Options | String | いいえ | はい | 拡張フィールド。 | このプロパティの値は JSON 文字列です。Deep Learning Containers (DLC) でデータセットを使用する場合、 mountPath フィールドを使用してデータセットのデフォルトのマウントパスを指定できます。 |
SourceType | String | いいえ | いいえ | データソースのタイプ。 | デフォルト値: USER。有効な値:
|
SourceId | String | いいえ | いいえ | データソースの ID。 |
|
ラベルの構文
"Labels": [
{
"Value": String, // ラベルの値
"Key": String // ラベルのキー
}
]ラベルのプロパティ
プロパティ | タイプ | 必須 | 編集可能 | 説明 | 制約 |
Key | String | はい | いいえ | ラベルのキー。 | キーは 1 ~ 128 文字で、 |
Value | String | いいえ | いいえ | ラベルの値。 | 値は最大 128 文字で、 |
戻り値
Fn::GetAtt
VersionName: データセットバージョンの名前。
例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
DataSourceType:
Type: String
Description:
en: |-
The data source type. The following values are supported:
- OSS: Alibaba Cloud Object Storage (OSS).
- NAS: Alibaba cloud file storage (NAS).
- CPFS
AllowedValues:
- OSS
- NAS
- CPFS
Required: true
Uri:
Type: String
Description:
en: |-
The Uri configuration sample is as follows:
- The data source type is OSS:'oss://bucket.endpoint/object'
- The data source type is NAS:
The general NAS format is: 'nas://<nasfisid>.region/subpath/to/dir/';
CPFS1.0:'nas://<cpfs-fsid>.region/subpath/to/dir /';
CPFS2.0:'nas://<cpfs-fsid>.region/<protocolserviceid>/'.
CPFS1.0 and CPFS2.0 are distinguished by the format of fsid: CPFS1.0 is cpfs-<8-bit ascii characters>;CPFS2.0 is cpfs-<16 ascii characters>.
AllowedPattern: ^(oss://|nas://).*
Required: true
Property:
Type: String
Description:
en: |-
The properties of the dataset. The following values are supported:
- FILE: FILE.
- DIRECTORY: folder.
AllowedValues:
- FILE
- DIRECTORY
Required: true
DatasetId:
Type: String
Description:
en: The ID of the dataset.
Required: true
Resources:
ExtensionResource:
Type: ALIYUN::PAI::DatasetVersion
Properties:
DataSourceType:
Ref: DataSourceType
Uri:
Ref: Uri
Property:
Ref: Property
DatasetId:
Ref: DatasetId
Outputs:
VersionName:
Description: Dataset version name.
Value:
Fn::GetAtt:
- ExtensionResource
- VersionName
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"DataSourceType": { // データソースタイプ
"Type": "String",
"Description": {
"en": "The data source type. The following values are supported:\n- OSS: Alibaba Cloud Object Storage (OSS).\n- NAS: Alibaba cloud file storage (NAS).\n- CPFS"
},
"AllowedValues": [
"OSS",
"NAS",
"CPFS"
],
"Required": true
},
"Uri": { // URI 設定
"Type": "String",
"Description": {
"en": "The Uri configuration sample is as follows:\n- The data source type is OSS:'oss://bucket.endpoint/object'\n- The data source type is NAS:\nThe general NAS format is: 'nas://<nasfisid>.region/subpath/to/dir/';\nCPFS1.0:'nas://<cpfs-fsid>.region/subpath/to/dir /';\nCPFS2.0:'nas://<cpfs-fsid>.region/<protocolserviceid>/'.\nCPFS1.0 and CPFS2.0 are distinguished by the format of fsid: CPFS1.0 is cpfs-<8-bit ascii characters>;CPFS2.0 is cpfs-<16 ascii characters>."
},
"AllowedPattern": "^(oss://|nas://).*",
"Required": true
},
"Property": { // プロパティ
"Type": "String",
"Description": {
"en": "The properties of the dataset. The following values are supported:\n- FILE: FILE.\n- DIRECTORY: folder."
},
"AllowedValues": [
"FILE",
"DIRECTORY"
],
"Required": true
},
"DatasetId": { // データセット ID
"Type": "String",
"Description": {
"en": "The ID of the dataset."
},
"Required": true
}
},
"Resources": {
"ExtensionResource": {
"Type": "ALIYUN::PAI::DatasetVersion",
"Properties": {
"DataSourceType": {
"Ref": "DataSourceType"
},
"Uri": {
"Ref": "Uri"
},
"Property": {
"Ref": "Property"
},
"DatasetId": {
"Ref": "DatasetId"
}
}
}
},
"Outputs": {
"VersionName": { // データセットバージョン名
"Description": "Dataset version name.",
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"VersionName"
]
}
}
}
}