머신러닝 5

Hugging Face, Training a causal language model from scratch

Training a causal language model from scratch - Hugging Face Course Up until now, we’ve mostly been using pretrained models and fine-tuning them for new use cases by reusing the weights from pretraining. As we saw in Chapter 1, this is commonly referred to as transfer learning, and it’s a very successful strategy for a huggingface.co Causal language model을 처음부터 학습시켜보는 강의 내용. 여기서 Text generation ..

Data/Information 2022.04.01

Hugging Face, Translation

Main NLP tasks - Hugging Face Course Let’s now dive into translation. This is another sequence-to-sequence task, which means it’s a problem that can be formulated as going from one sequence to another. In that sense the problem is pretty close to summarization, and you could adapt what we huggingface.co sequence-to-sequence task인 translation에 대해 학습해보자. task에 맞는 dataset을 불러오고 그 안의 샘플을 뽑아보았다. pipe..

Data/Information 2022.03.17

TensorFlow LongFormer NER Baseline

TensorFlow - LongFormer - NER - [CV 0.633] Explore and run machine learning code with Kaggle Notebooks | Using data from multiple data sources www.kaggle.com 캐글 공모전에 참가하면서 분석한 상위 링크의 코드를 리뷰하고자 한다. NLP 문제에 대해 Longformer 모델을 TensorFlow 구문으로 학습한 코드이다. Furthermore this notebook is one fold. It trains with 90% data and validates on 10% data. We can convert this notebook to K-fold or train with 100% d..

Data/코드 리뷰 2022.03.15

two longformer is better than one

two longformers are better than 1 Explore and run machine learning code with Kaggle Notebooks | Using data from multiple data sources www.kaggle.com 캐글 공모전에 참가하면서 분석한 상위 링크의 코드를 리뷰하고자 한다. NLP 문제에 대해 2개의 롱포머 모델을 사용한 코드이다. 패키지 불러오기 + 캐시 비워주기 NER 토큰 맵 만들어주기 + 경로 설정(배치와 최대 길이) input_ids(시작과 끝 부분에 특수 토큰 만들어주기) 와 attention mask 만들어주기 배치를 하나씩 가져와서 패딩을 달리 해주는 dynamic padding tez.Model을 arg로 받는 함수. AutoC..

Data/코드 리뷰 2022.03.15