Skip to main content

Tacademy project의 newsmodel을 학습하고 실험하기 위한 패키지 입니다.

Project description

newspiece mlflow

  • 현재 상황은 기존 model과 mlflow의 틀을 통합한 상황입니다.
  • 현 상황에서 주요한 파일은 newspiece.py입니다.
  • newspiece.py의 NewspieaceMain 클래스의 run_jsoninference는 inference를 담당하며, run_modeltrain은 모델 학습을 당당합니다.

Usage

Requirements

  • Python >= 3.7
  • PyTorch >= torch==1.8.2+cu111
  • tqdm
  • transformers >=4.16.2
  • mlflow==1.23.1
  • scipy>=1.8.0
  • nltk

Folder Structure

newsmodel/
│
├── main.py - preprocess 완료된 파일 파일을 만들고, 그걸 통해서 inference와 train을 담당하는 모듈(실행 가능)
│
├── model_run.py: 모델 학습과 실험을 mlflow 내부에서 할때 사용하는 모듈
│
│
├── inference/ - mlflow에 production 상태에 있는 모델을 불러와서 inference하는 모듈
│       ├──inference.py 
│
├── trainer/ - 기존에 있는 라벨링된 데이터를 기반으로 model을 train하는 모듈
│       ├── nlpmodel.py 
│
├── model/ - 사용될 전체 모델들이 class로 들어가 있는 파일(개별 모델별 py파일을 만들어야 하나 고민중.
│       ├──model.py
│
├── preprocess 
│       ├── preprocess.py - 전처리 모듈들을 사용해서 파일을 전처리하는 모듈
│       ├── textrank.py - textrank 알고리즘을 사용하기 위한 모듈이 있는 파일
│       ├── ner.py - ner model을 사용하기 위한 모듈이 있는 파일
│       ├── countryset.py - 국가쌍을 사용하기 위한 파일
│
├── dataloader
│       ├── dataio.py - json 파일과 xlsx 파일을 불러오는 모듈
│       ├── dataloader.py - 국가쌍을 사용하기 위한 파일
│
├── config.json - train의 설정에 필요한 컬럼과 파일 경로를 지정해준다.
├── utils.py - 모델 사전이 들어있는 파일
│
├── data/pgdata - parameter가 local에서 사용할 수 있는 경우에 local에서 사용할 데이터가 있는 폴더
│       ├── newsjson: 크롤링된 json 파일들이 들어가는 폴더 
│       └── labeled data: 라벨링된 파일이 들어가는 폴더
├── saved_model - 학습된 모델이 저장되는 폴더, inference에 사용하는 모듈을 불러오는 폴더
│
├── setup.py - package를 설치하는 모듈

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Newspiece-1.4-py3-none-any.whl (2.3 kB view details)

Uploaded Python 3

File details

Details for the file Newspiece-1.4-py3-none-any.whl.

File metadata

  • Download URL: Newspiece-1.4-py3-none-any.whl
  • Upload date:
  • Size: 2.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.7.12

File hashes

Hashes for Newspiece-1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 3d12350e9692764cb42e9118ca6dc0ecf4c6e0763ebe46d972449f6670aae7c1
MD5 586102c29dd8810f6dda5c28ba834dc9
BLAKE2b-256 c5dd211b2726648f8bc2ba4021e49c664582d7b486840118016fec2c93b8a5f7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page