src/transformers/models/marian/convert_marian_to_pytorch.py/convert
def convert(source_dir: Path, dest_dir):
    dest_dir = Path(dest_dir)
    dest_dir.mkdir(exist_ok=True)

    opus_state = OpusState(source_dir)

    # save tokenizer
    opus_state.tokenizer.save_pretrained(dest_dir)

    # save_json(opus_state.cfg, dest_dir / "marian_original_config.json")
    # ^^ Uncomment to save human readable marian config for debugging

    model = opus_state.load_marian_model()
    model = model.half()
    model.save_pretrained(dest_dir)
    model.from_pretrained(dest_dir)  # sanity check