데이터 세트 보기 - Amazon Lookout for Vision

기계 번역으로 제공되는 번역입니다. 제공된 번역과 원본 영어의 내용이 상충하는 경우에는 영어 버전이 우선합니다.

데이터 세트 보기

프로젝트에는 모델 학습 및 테스트에 사용되는 단일 데이터 세트가 있을 수 있습니다. 또는 학습 데이터 세트와 테스트 데이터 세트를 분리할 수도 있습니다. 콘솔을 사용하여 데이터 세트를 볼 수 있습니다. DescribeDataset 작업을 사용하여 데이터 세트에 대한 정보 (훈련 또는 테스트)를 가져올 수도 있습니다.

프로젝트의 데이터 세트 보기 (콘솔)

다음 절차의 단계를 수행하여 콘솔에서 프로젝트 데이터 세트를 봅니다.

데이터 세트를 보려면 (콘솔)
  1. https://console.aws.amazon.com/lookoutvision/에서 Amazon Lookout for Vision 콘솔을 엽니다.

  2. 시작하기를 선택합니다.

  3. 왼쪽 탐색 창에서 프로젝트를 선택합니다.

  4. 프로젝트 페이지에서 보려는 데이터 세트가 포함된 프로젝트를 선택합니다.

  5. 왼쪽 탐색 창에서 데이터 세트를 선택하여 데이터 세트 세부 정보를 봅니다. 학습 데이터 세트와 테스트 데이터 세트가 있는 경우 각 데이터 세트의 탭이 표시됩니다.

프로젝트 (SDK)의 데이터 세트 보기

DescribeDataset 작업을 사용하여 프로젝트와 관련된 학습 또는 테스트 데이터 세트에 대한 정보를 얻을 수 있습니다.

데이터 세트 (SDK)를 보려면
  1. 아직 설치 및 구성하지 않았다면 AWS CLI 및 AWS SDK를 설치하고 구성합니다. 자세한 내용은 4단계: 설정 AWS CLI 그리고 AWS SDKs 섹션을 참조하세요.

  2. 다음 예제 코드를 사용하여 데이터 세트를 확인하세요.

    CLI

    다음 값을 변경합니다.

    • project-name은 확인할 모델이 포함된 프로젝트 이름으로 변경합니다.

    • dataset-type은 보려는 데이터 세트 유형(train또는test)으로 변경합니다.

    aws lookoutvision describe-dataset --project-name project name\ --dataset-type train or test \ --profile lookoutvision-access
    Python

    이 코드는 AWS 설명서 SDK 예제 GitHub 리포지토리에서 가져왔습니다. 전체 예제는 여기에서 확인하세요.

    @staticmethod def describe_dataset(lookoutvision_client, project_name, dataset_type): """ Gets information about a Lookout for Vision dataset. :param lookoutvision_client: A Boto3 Lookout for Vision client. :param project_name: The name of the project that contains the dataset that you want to describe. :param dataset_type: The type (train or test) of the dataset that you want to describe. """ try: response = lookoutvision_client.describe_dataset( ProjectName=project_name, DatasetType=dataset_type ) print(f"Name: {response['DatasetDescription']['ProjectName']}") print(f"Type: {response['DatasetDescription']['DatasetType']}") print(f"Status: {response['DatasetDescription']['Status']}") print(f"Message: {response['DatasetDescription']['StatusMessage']}") print(f"Images: {response['DatasetDescription']['ImageStats']['Total']}") print(f"Labeled: {response['DatasetDescription']['ImageStats']['Labeled']}") print(f"Normal: {response['DatasetDescription']['ImageStats']['Normal']}") print(f"Anomaly: {response['DatasetDescription']['ImageStats']['Anomaly']}") except ClientError: logger.exception("Service error: problem listing datasets.") raise print("Done.")
    Java V2

    이 코드는 AWS 설명서 SDK 예제 GitHub 리포지토리에서 가져왔습니다. 전체 예제는 여기에서 확인하세요.

    /** * Gets the description for a Amazon Lookout for Vision dataset. * * @param lfvClient An Amazon Lookout for Vision client. * @param projectName The name of the project in which you want to describe a * dataset. * @param datasetType The type of the dataset that you want to describe (train * or test). * @return DatasetDescription A description of the dataset. */ public static DatasetDescription describeDataset(LookoutVisionClient lfvClient, String projectName, String datasetType) throws LookoutVisionException { logger.log(Level.INFO, "Describing {0} dataset for project {1}", new Object[] { datasetType, projectName }); DescribeDatasetRequest describeDatasetRequest = DescribeDatasetRequest.builder() .projectName(projectName) .datasetType(datasetType) .build(); DescribeDatasetResponse describeDatasetResponse = lfvClient.describeDataset(describeDatasetRequest); DatasetDescription datasetDescription = describeDatasetResponse.datasetDescription(); logger.log(Level.INFO, "Project: {0}\n" + "Created: {1}\n" + "Type: {2}\n" + "Total: {3}\n" + "Labeled: {4}\n" + "Normal: {5}\n" + "Anomalous: {6}\n", new Object[] { datasetDescription.projectName(), datasetDescription.creationTimestamp(), datasetDescription.datasetType(), datasetDescription.imageStats().total().toString(), datasetDescription.imageStats().labeled().toString(), datasetDescription.imageStats().normal().toString(), datasetDescription.imageStats().anomaly().toString(), }); return datasetDescription; }