Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🌐 [i18n-KO] Translated bitsandbytes.md to Korean #32408

Merged
merged 11 commits into from
Aug 8, 2024

Conversation

SeungAhSon
Copy link
Contributor

@SeungAhSon SeungAhSon commented Aug 4, 2024

What does this PR do?

Translated the bitsandbytes.md file of the documentation to Korean.
Thank you in advance for your review.

Part of #20179

Before reviewing

  • Check for missing / redundant translations (번역 누락/중복 검사)
  • Grammar Check (맞춤법 검사)
  • Review or Add new terms to glossary (용어 확인 및 추가)
  • Check Inline TOC (e.g. [[lowercased-header]])
  • Check live-preview for gotchas (live-preview로 정상작동 확인)

Who can review? (Initial)

@SeungAhSon, @Jwaminju, @thsamajiki, @4N3MONE, @jungnerd

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you read the contributor guideline,
    Pull Request section?
  • Was this discussed/approved via a Github issue or the forum? Please add a link
    to it if that's the case.
  • Did you make sure to update the documentation with your changes? Here are the
    documentation guidelines, and
    here are tips on formatting docstrings.
  • Did you write any new necessary tests?

Who can review? (Final)

@stevhliu May you please review this PR?

@SeungAhSon SeungAhSon marked this pull request as ready for review August 4, 2024 07:24
Copy link
Contributor

@junejae junejae left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR 서식에 주석이 (<!— PR의 제목은 "🌐 [i18n-KO] Translated <your_file>.md to Korean" 으로 부탁드립니다 —>) 노출되고 있습니다. 노출되지 않도록 수정 부탁드립니다.

또한, 본 PR은 아직 OSSCA 팀원들에게 충분히 리뷰/검토되지 않은 PR입니다. PR의 상태를 Draft로 변경 부탁드립니다.

This PR hasn't been sufficiently reviewed by OSSCA members, Please change your PR's status to Draft.

docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
<hfoptions id="bnb">
<hfoption id="8-bit">

모델을 8비트로 양자화하면 메모리 사용량이 절반으로 줄어들며, 대형 모델의 경우 `device_map="auto"`를 설정하여 사용 가능한 GPU를 효율적으로 활용할 수 있습니다:
Copy link
Contributor

@Jwaminju Jwaminju Aug 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
모델을 8비트로 양자화하면 메모리 사용량이 절반으로 줄어들며, 대형 모델의 경우 `device_map="auto"`를 설정하여 사용 가능한 GPU를 효율적으로 활용할 수 있습니다:
모델을 8비트로 양자화하면 메모리 사용량이 절반으로 줄어들며, 대규모 모델의 경우 `device_map="auto"`를 설정하여 사용 가능한 GPU를 효율적으로 활용할 수 있습니다:

llm을 대규모 언어 모델로 번역하는 걸 보면, large도 대규모로 통일하면 어떨까 싶습니다.
띄어쓰기도 고쳤습니다!

docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
model_8bit.model.decoder.layers[-1].final_layer_norm.weight.dtype
```

모델이 8비트로 양자화되면 최신 버전의 Transformers와 bitsandbytes를 사용하지 않는 한 양자화된 가중치를 Hub에 푸시할 수 없습니다. 최신 버전을 사용하는 경우, [`~PreTrainedModel.push_to_hub`] 방법을 사용하여 8비트 모델을 Hub에 푸시할 수 있습니다. 양자화 구성 파일(config.json)이 먼저 푸시되고, 그 다음 양자화된 모델 가중치가 푸시됩니다.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
모델이 8비트로 양자화되면 최신 버전의 Transformers와 bitsandbytes를 사용하지 않는 한 양자화된 가중치를 Hub에 푸시할 수 없습니다. 최신 버전을 사용하는 경우, [`~PreTrainedModel.push_to_hub`] 방법을 사용하여 8비트 모델을 Hub에 푸시할 수 있습니다. 양자화 구성 파일(config.json)이 먼저 푸시되고, 그 다음 양자화된 모델 가중치가 푸시됩니다.
모델이 8비트로 양자화되면 최신 버전의 Transformers와 bitsandbytes를 사용하지 않는 한 양자화된 가중치를 Hub에 푸시할 수 없습니다. 최신 버전을 사용하는 경우, [`~PreTrainedModel.push_to_hub`] 메소드를 사용하여 8비트 모델을 Hub에 푸시할 수 있습니다. 양자화 구성 파일(config.json)이 먼저 푸시되고, 그 다음 양자화된 모델 가중치가 푸시됩니다.

glossary에 method는 메소드라고 번역되어 있네요!

docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
@SeungAhSon SeungAhSon marked this pull request as draft August 5, 2024 13:56
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved

### 미세 조정[[finetuning]]

[PEFT](https://github.com/huggingface/peft) 라이브러리를 사용하면 [flan-t5-large](https://huggingface.co/google/flan-t5-large) 및 [facebook/opt-6.7b](https://huggingface.co/facebook/opt-6.7b)와 같은 대형 모델을 8비트 양자화로 미세 조정할 수 있습니다. 훈련 시 `device_map` 매개변수를 전달할 필요가 없으며, 모델이 자동으로 GPU에 로드됩니다. 그러나 원하는 경우 `device_map` 매개변수로 장치 맵을 사용자 정의할 수 있습니다 (`device_map="auto"`는 추론에만 사용해야 합니다).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
[PEFT](https://github.com/huggingface/peft) 라이브러리를 사용하면 [flan-t5-large](https://huggingface.co/google/flan-t5-large)[facebook/opt-6.7b](https://huggingface.co/facebook/opt-6.7b)와 같은 대형 모델을 8비트 양자화로 미세 조정할 수 있습니다. 훈련 시 `device_map` 매개변수를 전달할 필요가 없으며, 모델이 자동으로 GPU에 로드됩니다. 그러나 원하는 경우 `device_map` 매개변수로 장치 맵을 사용자 정의할 수 있습니다 (`device_map="auto"`는 추론에만 사용해야 합니다).
[PEFT](https://github.com/huggingface/peft) 라이브러리를 사용하면 [flan-t5-large](https://huggingface.co/google/flan-t5-large)[facebook/opt-6.7b](https://huggingface.co/facebook/opt-6.7b)와 같은 대형 모델을 8비트 양자화로 미세 조정할 수 있습니다. 훈련 시 `device_map` 매개변수를 전달할 필요가 없으며, 모델을 자동으로 GPU에 가져옵니다. 그러나 원하는 경우 `device_map` 매개변수로 장치 맵을 사용자 정의할 수 있습니다 (`device_map="auto"`는 추론에만 사용해야 합니다).

글로서리 기반 수정입니다.

docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
</hfoption>
<hfoption id="4-bit">

모델을 4비트로 양자화하면 메모리 사용량이 4배 줄어들며, 대형 모델의 경우 `device_map="auto"`를 설정하여 사용 가능한 GPU를 효율적으로 활용할 수 있습니다:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
모델을 4비트로 양자화하면 메모리 사용량이 4배 줄어들며, 대형 모델의 경우 `device_map="auto"`를 설정하여 사용 가능한 GPU를 효율적으로 활용할 수 있습니다:
모델을 4비트로 양자화하면 메모리 사용량이 4배 줄어들며, 대규모 모델의 경우 `device_map="auto"`를 설정하여 사용 가능한 GPU를 효율적으로 활용할 수 있습니다:

glossary에서 llm을 대규모 언어 모델로 번역해서, large를 대규모로 번역해보았습니다.

docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
)
```

기본적으로 torch.nn.LayerNorm과 같은 다른 모듈은 `torch.float16`으로 변환됩니다. 원하면 `torch_dtype` 매개변수로 이 모듈의 데이터 유형을 변경할 수 있습니다:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://github.com/huggingface/transformers/pull/32408/files#r1703434051

FYI, 나중에 윗 부분이 결정된다면, 통일되면 좋을 것 같네요!

docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
@jungnerd
Copy link
Contributor

jungnerd commented Aug 6, 2024

좋은 번역 감사합니다!
PR 서식 맨 첫 줄 Translated the <your_file>.md file of the documentation to Korean. 부분의 <your_file>.md를 번역하신 문서로 수정해주세요!

Co-authored-by: wony617 <[email protected]>
Co-authored-by: YONGSANG <[email protected]>
Co-authored-by: Woojun Jung <[email protected]>
@SeungAhSon SeungAhSon marked this pull request as ready for review August 6, 2024 16:48
@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

Copy link
Member

@stevhliu stevhliu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice job, thanks for the translation! Can you check if whether removing the "?" in some of the sentences alters the meaning? Thanks! 🤗

docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
docs/source/ko/quantization/bitsandbytes.md Outdated Show resolved Hide resolved
Co-authored-by: Steven Liu <[email protected]>
@SeungAhSon
Copy link
Contributor Author

Nice job, thanks for the translation! Can you check if whether removing the "?" in some of the sentences alters the meaning? Thanks! 🤗

Thank you so much for checking! Your suggestion was spot on, so I've made the changes accordingly.

Copy link
Member

@stevhliu stevhliu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again!

@stevhliu stevhliu merged commit b01f9c4 into huggingface:main Aug 8, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants