Instructions to use McmanusChen/MCL-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Fairseq
How to use McmanusChen/MCL-base with Fairseq:
from fairseq.checkpoint_utils import load_model_ensemble_and_task_from_hf_hub models, cfg, task = load_model_ensemble_and_task_from_hf_hub( "McmanusChen/MCL-base" ) - Notebooks
- Google Colab
- Kaggle
File size: 278 Bytes
f5feb4c | 1 2 3 4 5 6 7 8 9 10 | import glob
import json
from sys import argv
for split in ['train', 'valid']:
with open(f'json/{split}.json', 'w') as f:
data = [{'source': glob.glob(f'shard/{split}/*'), 'source_lang': 'en', 'weight': 1.0, 'name': '16gb-en'}]
json.dump(data, f, indent=4)
|