728x90
반응형
Sharing models and tokenizers - Hugging Face Course
Using pretrained models The Model Hub makes selecting the appropriate model simple, so that using it in any downstream library can be done in a few lines of code. Let’s take a look at how to actually use one of these models, and how to contribute back to
huggingface.co
위의 링크의 내용

1. 파이프라인 패키지를 통해 불러오기
- 가장 단순하지만 Task에 맞는 모델을 불러와야함.
2. 모델 아키텍쳐 패키지를 통해 불러오기
3. 오토클래스 패키지를 통해 불러오기
- 체크포인트에 따라 토크나이저, 모델을 불러주기에 가장 간편

Hugging Face의 Models 탭을 통해 활용가능한 모델들을 확인할 수 있고
모델을 클릭하여 보면

이렇게 Model Card를 통해 모델 설명을 볼 수 있으며
오른쪽의 Train, Depoly, Use in Transformers 등의 버튼을 통해

이렇게 활용 코드를 따올 수 있다.
출처
728x90
반응형
'공부정리 > NLP' 카테고리의 다른 글
| [NLP] Sentence transformer를 이용하여 텍스트 유사도 구하기 with korQuad Dataset - (3) 명사 추출 (1) | 2022.10.18 |
|---|---|
| [NLP] Sentence transformer를 이용하여 텍스트 유사도 구하기 with korQuad Dataset - (2) (1) | 2022.10.18 |
| [NLP] Sentence transformer를 이용하여 텍스트 유사도 구하기 with korQuad Dataset (1) | 2022.10.14 |
| [NLP] 자연어 처리를 위한 데이터 셋 모음 (0) | 2022.10.14 |
| [NLP] KorQuAD dataset 기반 챗봇 만들기 (0) | 2022.10.13 |