pythrch1 클리핑된 뉴스 모델에 통과시켜서 성능확인하기 모델 학습 코드 !pip install transformers !pip install torch import pandas as pd from sklearn.model_selection import train_test_split import json # JSON 데이터 불러오기 file_path = '/content/news_data.json' # 앞에서 생성한 JSON 파일 경로를 사용합니다. with open(file_path, 'r', encoding='utf-8') as file: data = json.load(file) # JSON 데이터를 DataFrame으로 변환 data_df = pd.DataFrame(data) # 'Title'과 'CategoryID' 열을 사용하여 새로운 DataFram.. 2023. 12. 10. 이전 1 다음 728x90