NVIDIA-NeMo / NVIDIA-NeMo/RL

Add safe_serialization (safetensors) option to the checkpoint conversion script (`examples/convert_dcp_to_hf.py`)

Open
#491 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Python
Stars
2k
Forks
561
Avg merge
4d 5h
Merged PRs (30d)
145

Description

**Is your feature request related to a problem? Please describe.**

Currently, the ckpt conversion script `examples/convert_dcp_to_hf.py` saves model weights in `.bin` for the HF checkpoint. The user has to convert it to safetensors.

**Describe the solution you'd like**

HF has a feature. It should be something like add an option

```
model.save_pretrained(
...,
safe_serialization=True
)
```

https://github.com/NVIDIA/NeMo-RL/blob/main/examples/convert_dcp_to_hf.py

**Describe alternatives you've considered**

**Additional context**

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.