Skip to content

How to convert torchtune .pt output files? #1201

Answered by ebsmothers
troy256 asked this question in Q&A
Discussion options

You must be logged in to vote

@troy256 personally I would expect convert_hf_to_gguf.py to be a decent starting point (though I haven't tried it myself). But first you would need to convert from the Meta checkpoint format into the HF checkpoint format. There are basically two ways you can do this:

(1) re-run your fine-tuning job but replace Meta checkpointer with HF checkpointer. This isn't ideal since you have to re-run the fine-tuning job again, but the actual changes to do it should be pretty straightforward. You just need to make sure you have the HF versions of the checkpoints downloaded, you should be able to run something like this to do it:

tune download meta-llama/Meta-Llama-3-8B-Instruct --output-dir /tmp/Met…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@troy256
Comment options

Comment options

You must be logged in to vote
1 reply
@troy256
Comment options

Answer selected by troy256
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants