> ## Documentation Index
> Fetch the complete documentation index at: https://wb-21fd5541-docs-2516.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Artifact

export const GitHubLink = ({url, compact = false}) => <a href={url} target="_blank" rel="noopener noreferrer" className={compact ? "source-link" : "github-source-link"}>
    {compact ? "소스 보기" : <>
    <svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg">
      <path d="M12 0C5.37 0 0 5.37 0 12c0 5.31 3.435 9.795 8.205 11.385.6.105.825-.255.825-.57 0-.285-.015-1.23-.015-2.235-3.015.555-3.795-.735-4.035-1.41-.135-.345-.72-1.41-1.23-1.695-.42-.225-1.02-.78-.015-.795.945-.015 1.62.87 1.845 1.23 1.08 1.815 2.805 1.305 3.495.99.105-.78.42-1.305.765-1.605-2.67-.3-5.46-1.335-5.46-5.925 0-1.305.465-2.385 1.23-3.225-.12-.3-.54-1.53.12-3.18 0 0 1.005-.315 3.3 1.23.96-.27 1.98-.405 3-.405s2.04.135 3 .405c2.295-1.56 3.3-1.23 3.3-1.23.66 1.65.24 2.88.12 3.18.765.84 1.23 1.905 1.23 3.225 0 4.605-2.805 5.625-5.475 5.925.435.375.81 1.095.81 2.22 0 1.605-.015 2.895-.015 3.3 0 .315.225.69.825.57A12.02 12.02 0 0024 12c0-6.63-5.37-12-12-12z" />
    </svg>
    GitHub 소스 코드
      </>}
  </a>;

<GitHubLink compact url="https://github.com/wandb/wandb/blob/main/wandb/sdk/artifacts/artifact.py#L128" />

## <Badge color="yellow" size="lg" shape="rounded">클래스</Badge> wandb.Artifact

데이터셋과 모델 버전 관리를 위한 유연하고 가벼운 구성 요소입니다.

빈 W\&B 아티팩트를 생성합니다. `add`로 시작하는 메서드로 아티팩트의 콘텐츠를 채우세요. 아티팩트에 원하는 파일이 모두 추가되면 `run.log_artifact()`를 호출해 기록할 수 있습니다.

```python theme={null}
name: 'str',
type: 'str',
description: 'str | None' = None,
metadata: 'dict[str, Any] | None' = None,
incremental: 'bool' = False,
use_as: 'str | None' = None,
storage_region: 'str | None' = None,
digest_algorithm: "Literal['MD5', 'XXH128']" = 'MD5'
```

<div id="args">
  ## 매개변수
</div>

<ResponseField name="name" type="str">
  아티팩트의 사람이 읽을 수 있는 이름입니다. 이 이름을 사용해 W\&B App UI에서 또는 프로그래밍 방식으로 특정 아티팩트를 파악할 수 있습니다. `use_artifact` Public API를 사용하면 대화형으로 아티팩트를 참조할 수 있습니다. 이름에는 문자, 숫자, 밑줄, 하이픈, 점을 포함할 수 있습니다. 이름은 프로젝트 전체에서 고유해야 합니다.
</ResponseField>

<ResponseField name="type" type="str">
  아티팩트의 유형입니다. 아티팩트의 유형을 사용해 아티팩트를 정리하고 서로 구분할 수 있습니다. 문자, 숫자, 밑줄, 하이픈, 점을 포함하는 문자열이라면 어떤 것이든 사용할 수 있습니다. 일반적인 유형으로는 `dataset` 또는 `model`이 있습니다. 아티팩트를 W\&B Model 레지스트리와 연결하려면 유형 문자열에 `model`을 포함하세요. 일부 유형은 내부용으로 예약되어 있어 사용자가 설정할 수 없습니다. 여기에는 `job` 및 `wandb-`로 시작하는 유형이 포함됩니다.
</ResponseField>

<ResponseField name="description" type="str | None">
  아티팩트에 대한 설명입니다. Model 또는 Dataset Artifacts의 경우, 표준화된 팀 모델 카드 또는 데이터셋 카드에 대한 문서를 추가하세요. `Artifact.description` 속성을 사용하거나 W\&B App UI에서 아티팩트 설명을 조회할 수 있습니다. W\&B는 W\&B App에서 설명을 Markdown으로 렌더링합니다.
</ResponseField>

<ResponseField name="metadata" type="dict[str, Any] | None">
  아티팩트에 대한 추가 정보입니다. 메타데이터는 키-값 쌍의 사전으로 지정하세요. 전체 키는 최대 100개까지만 지정할 수 있습니다.
</ResponseField>

<ResponseField name="incremental" type="bool">
  기존 아티팩트를 수정하려면 대신 `Artifact.new_draft()` 방법을 사용하세요.
</ResponseField>

<ResponseField name="use_as" type="str | None">
  사용 중단되었습니다.
</ResponseField>

<ResponseField name="storage_region" type="str | None">
  설명이 제공되지 않았습니다.
</ResponseField>

<ResponseField name="digest_algorithm" type="Literal['MD5', 'XXH128']">
  아티팩트에 사용할 다이제스트 알고리즘입니다. 기본값은 MD5입니다. XXH128로 설정하면 이미 MD5를 사용하는 컬렉션의 일부인 경우를 제외하고 아티팩트가 XXH128 알고리즘으로 해시됩니다. SDK 버전 0.29.0 이전에서는 XXH128 아티팩트에 대한 `artifact.verify()` Call이 항상 실패합니다.
</ResponseField>

<div id="properties">
  ## 속성
</div>

<ResponseField name="aliases" type="list[str]">
  아티팩트 버전에 부여된, 의미를 쉽게 파악할 수 있는 하나 이상의 참조 또는

  식별용 "별칭" 목록입니다.

  별칭은 프로그래밍 방식으로 참조할 수 있는 변경 가능한 참조입니다.
  W\&B App UI 또는 프로그래밍 방식으로 아티팩트의 별칭을 변경하세요.
  자세한 내용은 [새 아티팩트 버전 만들기](https://docs.wandb.ai/models/artifacts/create-a-new-artifact-version)를
  참조하세요.
</ResponseField>

<ResponseField name="collection" type="ArtifactCollection">
  이 아티팩트를 가져온 컬렉션입니다.

  컬렉션은 순서가 있는 아티팩트 버전 그룹입니다.
  이 아티팩트가 연결된 컬렉션에서 가져온 경우
  해당 컬렉션을 반환합니다. 그렇지 않으면
  아티팩트 버전이 원래 생성된 컬렉션을 반환합니다.

  아티팩트 버전이 원래 생성된 컬렉션을
  소스 시퀀스라고 합니다.
</ResponseField>

<ResponseField name="commit_hash" type="str">
  이 아티팩트를 커밋할 때 반환된 해시입니다.
</ResponseField>

<ResponseField name="created_at" type="str">
  아티팩트가 생성된 타임스탬프입니다.
</ResponseField>

<ResponseField name="description" type="str | None">
  아티팩트의 설명입니다.
</ResponseField>

<ResponseField name="digest" type="str">
  아티팩트의 논리적 다이제스트입니다.

  다이제스트는 아티팩트 콘텐츠의 체크섬입니다. 아티팩트의 다이제스트가 현재
  `latest` 버전과 같으면 `log_artifact`는 아무 작업도 수행하지 않습니다.
</ResponseField>

<ResponseField name="digest_algorithm" type="ArtifactDigestAlgorithm">
  아티팩트의 다이제스트를 계산하는 데 사용되는 다이제스트 알고리즘입니다.
</ResponseField>

<ResponseField name="entity" type="str">
  아티팩트 컬렉션이 속한 엔터티의 이름입니다.

  아티팩트가 링크인 경우 엔터티는 연결된 아티팩트의 엔터티입니다.
</ResponseField>

<ResponseField name="file_count" type="int">
  파일 수(레퍼런스 포함)입니다.
</ResponseField>

<ResponseField name="history_step" type="int | None">
  이 아티팩트의 소스 run에 대한 이력 메트릭을 로깅한 가장 가까운 step입니다.
</ResponseField>

<ResponseField name="id" type="str | None">
  아티팩트의 ID입니다.
</ResponseField>

<ResponseField name="is_link" type="bool">
  아티팩트가 링크 아티팩트인지 여부를 나타내는 불리언 플래그입니다.

  True: 아티팩트는 소스 아티팩트에 대한 링크 아티팩트입니다.
  False: 아티팩트는 소스 아티팩트입니다.
</ResponseField>

<ResponseField name="linked_artifacts" type="list[Artifact]">
  소스 아티팩트에 연결된 모든 아티팩트의 목록을 반환합니다.

  이 아티팩트가 링크 아티팩트인 경우(`artifact.is_link == True`),
  빈 목록을 반환합니다.

  결과는 500개로 제한됩니다.
</ResponseField>

<ResponseField name="linked_at" type="str | None">
  이 아티팩트가 현재 컬렉션에 연결된 시간입니다.

  연결된 아티팩트에만 유효하며, 그렇지 않은 경우 `None`을 반환합니다.
</ResponseField>

<ResponseField name="manifest" type="ArtifactManifest">
  아티팩트의 매니페스트입니다.

  매니페스트에는 모든 콘텐츠가 나열되며, 아티팩트가
  로깅된 후에는 변경할 수 없습니다.
</ResponseField>

<ResponseField name="metadata" type="dict">
  사용자 정의 아티팩트 메타데이터입니다.

  아티팩트와 연결된 구조화된 데이터입니다.
</ResponseField>

<ResponseField name="name" type="str">
  아티팩트의 이름 및 버전입니다.

  형식이 `{collection}:{alias}`인 string입니다. 아티팩트가
  로깅/저장되기 전에 가져온 경우 이름에는 별칭이 포함되지 않습니다.
  아티팩트가 링크인 경우 이름은 연결된 아티팩트의 이름입니다.
</ResponseField>

<ResponseField name="project" type="str">
  아티팩트 컬렉션이 속한 프로젝트의 이름입니다.

  아티팩트가 링크인 경우 프로젝트는 연결된 아티팩트의 프로젝트입니다.
</ResponseField>

<ResponseField name="qualified_name" type="str">
  아티팩트의 엔터티/프로젝트/이름입니다.

  아티팩트가 링크인 경우 정규화된 이름은
  연결된 아티팩트 경로의 정규화된 이름입니다.
</ResponseField>

<ResponseField name="size" type="int">
  바이트 단위의 아티팩트 총 크기입니다.

  이 아티팩트가 추적하는 모든 레퍼런스를 포함합니다.
</ResponseField>

<ResponseField name="source_artifact" type="Artifact">
  원본으로 로깅된 아티팩트인 소스 아티팩트를 반환합니다.

  이 아티팩트가 소스 아티팩트인 경우(`artifact.is_link == False`),
  자기 자신을 반환합니다.
</ResponseField>

<ResponseField name="source_collection" type="ArtifactCollection">
  아티팩트의 소스 컬렉션입니다.

  소스 컬렉션은 아티팩트가 로깅된 컬렉션입니다.
</ResponseField>

<ResponseField name="source_entity" type="str">
  소스 아티팩트 엔터티의 이름입니다.
</ResponseField>

<ResponseField name="source_name" type="str">
  소스 아티팩트의 이름 및 버전입니다.

  형식이 `{source_collection}:{alias}`인 string입니다. 아티팩트가
  저장되기 전에는 버전을 아직 알 수 없으므로 이름만 포함합니다.
</ResponseField>

<ResponseField name="source_project" type="str">
  소스 아티팩트의 프로젝트 이름입니다.
</ResponseField>

<ResponseField name="source_qualified_name" type="str">
  소스 아티팩트의 source\_entity/source\_project/source\_name입니다.
</ResponseField>

<ResponseField name="source_version" type="str">
  소스 아티팩트의 버전입니다.

  `v{number}` 형식의 string입니다.
</ResponseField>

<ResponseField name="state" type="str">
  아티팩트의 상태입니다. 다음 중 하나입니다: "PENDING", "COMMITTED" 또는 "DELETED".
</ResponseField>

<ResponseField name="tags" type="list[str]">
  이 아티팩트 버전에 부여된 하나 이상의 태그 목록입니다.
</ResponseField>

<ResponseField name="ttl" type="timedelta | None">
  artifact의 TTL(time-to-live) 정책입니다.

  TTL 정책 기간이 지나면 Artifacts는 곧 삭제됩니다.
  `None`으로 설정하면 artifact의 TTL 정책이 비활성화되며, 팀 기본 TTL이 있더라도 삭제 예약되지 않습니다.
  팀 관리자가 기본
  TTL을 정의했고 artifact에 맞춤형 정책이 설정되어 있지 않으면, artifact는
  팀 기본 TTL 정책을 상속받습니다.
</ResponseField>

<ResponseField name="type" type="str">
  아티팩트의 유형입니다. 일반적인 유형에는 `dataset` 또는 `model`이 포함됩니다.
</ResponseField>

<ResponseField name="updated_at" type="str">
  아티팩트가 마지막으로 업데이트된 시간입니다.
</ResponseField>

<ResponseField name="url" type="The URL of the artifact.">
  아티팩트의 URL을 구성합니다.
</ResponseField>

<ResponseField name="use_as" type="str | None">
  사용 중단.
</ResponseField>

<ResponseField name="version" type="str">
  아티팩트의 버전입니다.

  `v{number}` 형식의 string입니다.
  이것이 연결 아티팩트인 경우 버전은 연결된 컬렉션에서 가져옵니다.
</ResponseField>

<div id="methods">
  ## 메서드
</div>

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.add()

```python theme={null}
self,
obj: 'WBValue',
name: 'StrPath',
overwrite: 'bool' = False
```

wandb.WBValue `obj`를 artifact에 추가합니다.

##### 인수

<ResponseField name="obj" type="WBValue">
  추가할 객체입니다. 현재 Bokeh, JoinedTable, PartitionedTable, Table, Classes, ImageMask, BoundingBoxes2D, Audio, Image, Video, Html, Object3D 중 하나를 지원합니다.
</ResponseField>

<ResponseField name="name" type="StrPath">
  객체를 추가할 artifact 내부 경로입니다.
</ResponseField>

<ResponseField name="overwrite" type="bool">
  True인 경우, 해당하면 동일한 파일 경로를 가진 기존 객체를 덮어씁니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactFinalizedError`:  현재 artifact 버전은 이미 확정되어 변경할 수 없습니다. 대신 새 artifact 버전을 로그하세요.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.add\_dir()

```python theme={null}
self,
local_path: 'str',
name: 'str | None' = None,
skip_cache: 'bool | None' = False,
policy: "Literal['mutable', 'immutable'] | None" = 'mutable',
merge: 'bool' = False
```

로컬 디렉터리를 artifact에 추가합니다.

##### 인수

<ResponseField name="local_path" type="str">
  로컬 디렉터리 경로입니다.
</ResponseField>

<ResponseField name="name" type="str | None">
  artifact 내 하위 디렉터리 이름입니다. 지정한 이름은 W\&B App UI에서 artifact의 `type` 아래에 중첩되어 표시됩니다. 기본값은 artifact의 루트입니다.
</ResponseField>

<ResponseField name="skip_cache" type="bool | None">
  `True`로 설정하면 W\&B는 업로드 중 파일을 캐시로 복사하거나 이동하지 않습니다.
</ResponseField>

<ResponseField name="policy" type="Literal['mutable', 'immutable'] | None">
  기본값은 "mutable"입니다.

  * mutable: 업로드 중 손상을 방지하기 위해 파일의 임시 복사본을 생성합니다.
  * immutable: 보호를 비활성화하고, 사용자가 파일을 삭제하거나 변경하지 않는다고 가정합니다.
</ResponseField>

<ResponseField name="merge" type="bool">
  `False`(기본값)인 경우, 이전 `add_dir` call에서 이미 추가된 파일의 내용이 변경되었으면 ValueError를 발생시킵니다. `True`인 경우, 내용이 변경된 기존 파일을 덮어씁니다. 새 파일은 항상 추가하고 파일은 제거하지 않습니다. 전체 디렉터리를 교체하려면 디렉터리를 추가할 때 `add_dir(local_path, name=my_prefix)`로 이름을 전달하고, `remove(my_prefix)`를 호출해 디렉터리를 제거한 뒤 다시 추가하세요.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactFinalizedError`: 현재 artifact 버전은 finalized 상태이므로 변경할 수 없습니다. 대신 새 artifact 버전을 log하세요.
* `ValueError`: Policy는 "mutable" 또는 "immutable"이어야 합니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.add\_file()

```python theme={null}
self,
local_path: 'str',
name: 'str | None' = None,
is_tmp: 'bool | None' = False,
skip_cache: 'bool | None' = False,
policy: "Literal['mutable', 'immutable'] | None" = 'mutable',
overwrite: 'bool' = False
```

로컬 파일을 artifact에 추가합니다.

##### 인수

<ResponseField name="local_path" type="str">
  추가할 파일의 경로입니다.
</ResponseField>

<ResponseField name="name" type="str | None">
  추가할 파일에 사용할 artifact 내부 경로입니다. 기본값은 파일의 기본 이름입니다.
</ResponseField>

<ResponseField name="is_tmp" type="bool | None">
  `true`이면 충돌을 방지하기 위해 파일 이름을 결정적으로 변경합니다.
</ResponseField>

<ResponseField name="skip_cache" type="bool | None">
  `True`이면 업로드한 후 파일을 캐시에 복사하지 않습니다.
</ResponseField>

<ResponseField name="policy" type="Literal['mutable', 'immutable'] | None">
  기본값은 "mutable"입니다. "mutable"로 설정하면 업로드 중 손상을 방지하기 위해 파일의 임시 복사본을 생성합니다. "immutable"로 설정하면 보호를 비활성화하고, 사용자가 파일을 삭제하거나 변경하지 않는다고 가정합니다.
</ResponseField>

<ResponseField name="overwrite" type="bool">
  `True`이면 파일이 이미 존재할 경우 덮어씁니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactFinalizedError`: 현재 artifact 버전은 finalized 상태이므로 변경할 수 없습니다. 대신 새 artifact 버전을 log하세요.
* `ValueError`: Policy는 "mutable" 또는 "immutable"이어야 합니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.add\_reference()

```python theme={null}
self,
uri: 'ArtifactManifestEntry | str',
name: 'StrPath | None' = None,
checksum: 'bool' = True,
max_objects: 'int | None' = None
```

URI로 지정된 레퍼런스를 아티팩트에 추가합니다.

아티팩트에 추가하는 파일이나 디렉터리와 달리, 레퍼런스는 W\&B에 업로드되지 않습니다. 자세한 내용은 [외부 파일 추적](https://docs.wandb.ai/models/artifacts/track-external-files)을 참조하세요.

기본적으로 다음 스키마를 지원합니다.

* http(s): 파일의 크기와 다이제스트는 서버가 반환한
  `Content-Length` 및 `ETag` 응답 헤더를 바탕으로 추론됩니다.
* s3: 체크섬과 크기는 객체 메타데이터에서 가져옵니다.
  bucket versioning이 활성화된 경우 버전 ID도 함께 추적됩니다.
* gs: 체크섬과 크기는 객체 메타데이터에서 가져옵니다. bucket
  versioning이 활성화된 경우 버전 ID도 함께 추적됩니다.
* https, `*.blob.core.windows.net`와 일치하는 도메인
* Azure: 체크섬과 크기는 blob 메타데이터에서 가져옵니다.
  storage account versioning이 활성화된 경우 버전 ID도 함께
  추적됩니다.
* file: 체크섬과 크기는 파일 시스템에서 가져옵니다. 이 스키마는
  추적하되 반드시 업로드할 필요는 없는 파일이 포함된 NFS 공유 또는 기타 외부 마운트 볼륨이 있을 때 유용합니다.

그 밖의 스키마에서는 다이제스트가 단순히 URI의 해시가 되며, 크기는 비워
둡니다.

##### 인수

<ResponseField name="uri" type="ArtifactManifestEntry | str">
  추가할 레퍼런스의 URI 경로입니다. URI 경로는 다른 아티팩트 항목에 대한 레퍼런스를 저장하기 위해 `Artifact.get_entry`에서 반환된 객체일 수도 있습니다.
</ResponseField>

<ResponseField name="name" type="StrPath | None">
  이 레퍼런스의 내용을 배치할 아티팩트 내 경로입니다.
</ResponseField>

<ResponseField name="checksum" type="bool">
  레퍼런스 URI에 있는 리소스의 체크섬을 계산할지 여부입니다. 체크섬 계산은 자동 무결성 검증을 가능하게 하므로 강력히 권장됩니다. 체크섬 계산을 비활성화하면 아티팩트 생성 속도는 빨라지지만, 레퍼런스 디렉터리를 순회하지 않으므로 디렉터리 안의 객체는 아티팩트에 저장되지 않습니다. 레퍼런스 객체를 추가할 때는 `checksum=False`로 설정하는 것을 권장하며, 이 경우 레퍼런스 URI가 변경될 때만 새 버전이 생성됩니다.
</ResponseField>

<ResponseField name="max_objects" type="int | None">
  디렉터리 또는 bucket 저장소 prefix를 가리키는 레퍼런스를 추가할 때 고려할 최대 객체 수입니다. 기본적으로 Amazon S3, GCS, Azure 및 로컬 파일에서 허용되는 최대 객체 수는 10,000,000입니다. 다른 URI 스키마에는 최대값이 없습니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactFinalizedError`:  현재 artifact 버전은 이미 확정되어 변경할 수 없습니다. 대신 새 artifact 버전을 로그하세요.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.checkout()

```python theme={null}
self,
root: 'str | None' = None
```

지정한 루트 디렉터리를 artifact의 내용으로 대체합니다.

WARNING: artifact에 포함되지 않은 `root`의 모든 파일이 삭제됩니다.

##### 인수

<ResponseField name="root" type="str | None">
  이 artifact의 파일로 대체할 디렉터리입니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.delete()

```python theme={null}
self,
delete_aliases: 'bool' = False
```

아티팩트와 해당 파일을 삭제합니다.

연결된 아티팩트에 대해 호출하면 링크만 삭제되며, 원본 아티팩트는 영향을 받지 않습니다.

원본 아티팩트와 컬렉션 간의 링크를 제거하려면 `Artifact.delete()` 대신 `Artifact.unlink()`를 사용하세요.

<div id="arguments">
  ##### 매개변수
</div>

<ResponseField name="delete_aliases" type="bool">
  `True`로 설정하면 아티팩트와 연결된 모든 alias를 삭제합니다. `False`이면 아티팩트에 기존 alias가 있을 경우 예외를 발생시킵니다. 아티팩트를 연결된 컬렉션에서 조회한 경우 이 매개변수는 무시됩니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.download()

```python theme={null}
self,
root: 'StrPath | None' = None,
allow_missing_references: 'bool' = False,
skip_cache: 'bool | None' = None,
path_prefix: 'StrPath | None' = None,
multipart: 'bool | None' = None
```

artifact의 내용을 지정된 루트 디렉터리로 다운로드합니다.

`root` 내의 기존 파일은 수정되지 않습니다. `root`의 내용이 artifact와 정확히 일치하도록 하려면 `download`를 호출하기 전에 `root`를 명시적으로 삭제하세요.

##### 인수

<ResponseField name="root" type="StrPath | None">
  W\&B가 artifact 파일을 저장하는 디렉터리입니다.
</ResponseField>

<ResponseField name="allow_missing_references" type="bool">
  `True`로 설정하면 레퍼런스된 파일을 다운로드하는 동안 유효하지 않은 레퍼런스 경로를 모두 무시합니다.
</ResponseField>

<ResponseField name="skip_cache" type="bool | None">
  `True`로 설정하면 다운로드 시 artifact 캐시를 건너뛰며, W\&B는 각 파일을 기본 루트 또는 지정한 다운로드 디렉터리로 다운로드합니다.
</ResponseField>

<ResponseField name="path_prefix" type="StrPath | None">
  지정하면 경로가 주어진 접두사로 시작하는 파일만 다운로드합니다. Unix 형식(슬래시 `/`)을 사용합니다.
</ResponseField>

<ResponseField name="multipart" type="bool | None">
  `None`(기본값)으로 설정하면 개별 파일 크기가 2GB보다 큰 경우 multipart 다운로드를 사용해 artifact를 병렬로 다운로드합니다. `True` 또는 `False`로 설정하면 파일 크기와 관계없이 artifact를 각각 병렬 또는 직렬로 다운로드합니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.file()

```python theme={null}
self,
root: 'str | None' = None
```

`root`로 지정한 디렉터리로 단일 파일 artifact를 다운로드합니다.

##### 인수

<ResponseField name="root" type="str | None">
  파일을 저장할 루트 디렉터리입니다. 기본값은 `./artifacts/self.name/`입니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: artifact가 로깅되지 않은 경우.
* `ValueError`: artifact에 파일이 두 개 이상 포함된 경우.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.files()

```python theme={null}
self,
names: 'list[str] | None' = None,
per_page: 'int' = 50,
start: 'str | None' = None
```

이 아티팩트에 저장된 모든 파일을 순회합니다.

##### 인수

<ResponseField name="names" type="list[str] | None">
  나열할 아티팩트 루트를 기준으로 한 파일 경로입니다.
</ResponseField>

<ResponseField name="per_page" type="int">
  요청당 반환할 파일 수입니다.
</ResponseField>

<ResponseField name="start" type="str | None">
  이전 paginator의 `.cursor` 속성에서 캡처한, 이전 쿼리를 이어서 수행하기 위한 페이지네이션 커서입니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.finalize()

```python theme={null}
self
```

artifact 버전을 최종 확정합니다.

artifact는 특정 버전으로 로깅되므로, 최종 확정된 후에는 해당 artifact 버전을 수정할 수 없습니다. artifact에 데이터를 더 로깅하려면 새 artifact 버전을 만드세요. `log_artifact`로 artifact를 로깅하면 artifact는 자동으로 최종 확정됩니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.get()

```python theme={null}
self,
name: 'str'
```

artifact를 기준으로 상대 `name`에 있는 WBValue 객체를 조회합니다.

##### 인수

<ResponseField name="name" type="str">
  조회할 artifact 기준 상대 name입니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: artifact가 로깅되지 않았거나 run이 오프라인인 경우.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.get\_added\_local\_path\_name()

```python theme={null}
self,
local_path: 'str'
```

로컬 파일 시스템 경로로 추가한 파일의 artifact 상대 이름을 조회합니다.

##### 인수

<ResponseField name="local_path" type="str">
  artifact 상대 이름으로 확인할 로컬 경로입니다.
</ResponseField>

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.get\_entry()

```python theme={null}
self,
name: 'StrPath'
```

지정한 이름의 entry를 조회합니다.

##### 인수

<ResponseField name="name" type="StrPath">
  조회할 artifact의 상대 이름
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: artifact가 로깅되지 않았거나 run이 오프라인인 경우
* `KeyError`: artifact에 지정한 이름의 entry가 없는 경우

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.get\_path()

```python theme={null}
self,
name: 'StrPath'
```

사용 중단되었습니다. `get_entry(name)`을 사용하세요.

##### 인수

<ResponseField name="name" type="StrPath">
  설명이 없습니다.
</ResponseField>

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.is\_draft()

```python theme={null}
self
```

artifact가 저장되지 않은 상태인지 확인합니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.json\_encode()

```python theme={null}
self
```

JSON 형식으로 인코딩된 artifact를 반환합니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.link()

```python theme={null}
self,
target_path: 'str',
aliases: 'Iterable[str] | None' = None
```

이 artifact를 컬렉션에 연결합니다.

##### 인수

<ResponseField name="target_path" type="str">
  컬렉션의 경로입니다. 경로는 접두사 "wandb-registry-", 레지스트리 이름, 컬렉션 이름으로 구성되며 형식은 `wandb-registry-{REGISTRY_NAME}/{COLLECTION_NAME}`입니다.
</ResponseField>

<ResponseField name="aliases" type="Iterable[str] | None">
  연결할 artifact에 하나 이상의 alias를 추가합니다. "latest" alias는 연결한 가장 최근 artifact에 자동으로 적용됩니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.logged\_by()

```python theme={null}
self
```

원래 artifact를 로깅한 W\&B run을 조회합니다.

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.new\_draft()

```python theme={null}
self
```

이 커밋된 artifact와 동일한 내용을 가진 새 초안 artifact를 생성합니다.

기존 artifact를 수정하면 "증분 artifact"라고 하는 새 artifact 버전이 생성됩니다. 반환된 artifact는 확장하거나 수정한 후 새 버전으로 로깅할 수 있습니다.

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.new\_file()

```python theme={null}
self,
name: 'str',
mode: 'str' = 'x',
encoding: 'str | None' = None,
policy: "Literal['mutable', 'immutable']" = 'mutable'
```

새 임시 파일을 열어 아티팩트에 추가합니다.

##### 인수

<ResponseField name="name" type="str">
  아티팩트에 추가할 새 파일의 이름입니다.
</ResponseField>

<ResponseField name="mode" type="str">
  새 파일을 열 때 사용할 파일 액세스 모드입니다.
</ResponseField>

<ResponseField name="encoding" type="str | None">
  새 파일을 열 때 사용할 인코딩입니다.
</ResponseField>

<ResponseField name="policy" type="Literal['mutable', 'immutable']">
  기본값은 "mutable"입니다. "mutable"로 설정하면 업로드 중 손상을 방지하기 위해 파일의 임시 복사본을 생성합니다. "immutable"로 설정하면 보호를 비활성화하고, 사용자가 파일을 삭제하거나 변경하지 않는다고 가정합니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactFinalizedError`:  현재 artifact 버전은 이미 확정되어 변경할 수 없습니다. 대신 새 artifact 버전을 로그하세요.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.remove()

```python theme={null}
self,
item: 'StrPath | ArtifactManifestEntry'
```

artifact에서 항목을 제거합니다.

##### 인수

<ResponseField name="item" type="StrPath | ArtifactManifestEntry">
  제거할 항목입니다. 특정 manifest 항목이거나 artifact 기준 상대 경로 이름일 수 있습니다. `item`이 디렉터리와 일치하면 해당 디렉터리의 모든 항목이 제거됩니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactFinalizedError`: 현재 artifact 버전이 finalized 상태이므로 변경할 수 없습니다. 대신 새 artifact 버전을 log하세요.
* `FileNotFoundError`: artifact에서 해당 항목을 찾을 수 없는 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.save()

```python theme={null}
self,
project: 'str | None' = None,
settings: 'wandb.Settings | None' = None
```

artifact에 적용한 변경 사항을 저장합니다.

현재 run 컨텍스트에 있으면 해당 run에 이 artifact가 기록됩니다. 현재 run 컨텍스트에 없으면 이
artifact를 추적하기 위해 유형이 "auto"인 run이 생성됩니다.

##### 인수

<ResponseField name="project" type="str | None">
  아직 run 컨텍스트에 없는 경우 artifact에 사용할 프로젝트입니다.
</ResponseField>

<ResponseField name="settings" type="wandb.Settings | None">
  자동 run을 초기화할 때 사용할 설정 객체입니다. 주로 테스트 하니스에서 사용합니다.
</ResponseField>

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.unlink()

```python theme={null}
self
```

이 artifact가 artifact collection에 연결된 멤버인 경우 연결을 해제합니다.

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: artifact가 로깅되지 않은 경우.
* `ValueError`: artifact가 어떤 collection에도 연결되어 있지 않은 경우.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.used\_by()

```python theme={null}
self
```

이 artifact와 여기에 연결된 artifact를 사용한 run의 목록을 조회합니다.

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: 아티팩트가 로깅되지 않은 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.verify()

```python theme={null}
self,
root: 'str | None' = None
```

artifact의 내용이 매니페스트와 일치하는지 확인합니다.

디렉터리의 모든 파일에 대해 체크섬을 계산한 다음, 해당 체크섬을 artifact의 매니페스트와 대조합니다. 레퍼런스는 확인하지 않습니다.

##### 인수

<ResponseField name="root" type="str | None">
  확인할 디렉터리입니다. None이면 artifact를 './artifacts/self.name/'에 다운로드합니다.
</ResponseField>

<div id="raises">
  ##### 예외
</div>

* `ArtifactNotLoggedError`: artifact가 로깅되지 않은 경우입니다.
* `ValueError`: 확인에 실패한 경우입니다.

### <Badge color="blue" size="lg" shape="rounded">방법</Badge> Artifact.wait()

```python theme={null}
self,
timeout: 'int | None' = None
```

필요한 경우 이 artifact의 logging이 완료될 때까지 기다립니다.

##### 인수

<ResponseField name="timeout" type="int | None">
  기다릴 시간(초)입니다.
</ResponseField>
