Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Unified Checkpoint] Checkpoint compression #9183

Merged
merged 44 commits into from
Nov 25, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
cd4e5e0
checkpoint compression init
wtmlon Sep 23, 2024
7684576
add ckpt quant argument
wtmlon Sep 24, 2024
afcecad
add ckpt quant ci
wtmlon Oct 11, 2024
d8f3351
fix ci
wtmlon Oct 11, 2024
434bd4c
fix lint
wtmlon Oct 11, 2024
a98fb8b
remove stage O2, change O3 --> O2
wtmlon Oct 11, 2024
2e5c73b
support async save
wtmlon Oct 11, 2024
6b1f3bf
file adjustment
wtmlon Oct 14, 2024
c4a80e7
magic string remove
wtmlon Oct 14, 2024
ae305a9
ci fix
wtmlon Oct 14, 2024
fd6ad57
ci fix, code refinement
wtmlon Oct 14, 2024
f766d15
function extraction
wtmlon Oct 15, 2024
e74b68b
fix ci
wtmlon Oct 15, 2024
a7b053d
code refinement
wtmlon Oct 15, 2024
10b1064
fix ci
wtmlon Oct 15, 2024
ad1dc75
fix ci
wtmlon Oct 15, 2024
fb2c2e9
Merge branch 'develop' of https://github.com/PaddlePaddle/PaddleNLP i…
wtmlon Oct 16, 2024
a1c35af
support non merge tp ckpt quantization
wtmlon Oct 18, 2024
f8530c0
fix ci
wtmlon Oct 18, 2024
4e21fb9
update
wtmlon Oct 18, 2024
a602fe5
fix bug
wtmlon Oct 21, 2024
55b8639
code refactor
wtmlon Oct 25, 2024
3a87734
Merge branch 'develop' of https://github.com/PaddlePaddle/PaddleNLP i…
wtmlon Oct 25, 2024
a3073aa
fix lint
wtmlon Oct 25, 2024
8a8aca7
fix ci
wtmlon Oct 25, 2024
bab5235
Merge branch 'develop' of https://github.com/PaddlePaddle/PaddleNLP i…
wtmlon Oct 28, 2024
c3c500d
del old uc.py
wtmlon Oct 28, 2024
a45c7f6
fix lint
wtmlon Oct 28, 2024
a4a3e23
add mgpu ci
wtmlon Oct 28, 2024
2330839
fix ci
wtmlon Oct 28, 2024
3fcd471
multi thread loading
wtmlon Oct 28, 2024
f57aab5
fix lint
wtmlon Oct 28, 2024
50ee148
Merge branch 'develop' of https://github.com/PaddlePaddle/PaddleNLP i…
wtmlon Oct 29, 2024
75a1011
fix bug
wtmlon Nov 5, 2024
ffd0823
Merge branch 'develop' of https://github.com/PaddlePaddle/PaddleNLP i…
wtmlon Nov 5, 2024
4947a8c
refactor code
wtmlon Nov 7, 2024
3eaebbb
Merge branch 'develop' of https://github.com/PaddlePaddle/PaddleNLP i…
wtmlon Nov 19, 2024
a6b2236
add comment
wtmlon Nov 19, 2024
a5d0afa
fix lint
wtmlon Nov 19, 2024
fdd92a8
add comment
wtmlon Nov 19, 2024
b2b20be
add comment
wtmlon Nov 19, 2024
432e97c
fix bug
wtmlon Nov 20, 2024
5eb201c
fix bugs when ckpt no quant and no master weight
wtmlon Nov 21, 2024
b2bcf16
remove uni-test
wtmlon Nov 22, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion paddlenlp/peft/lora/lora_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ def from_pretrained(cls, model, lora_path, **kwargs):
pre_tensor_parallel_split = True
tp_actions = lora_model._get_tensor_parallel_convert_actions(loaded_keys, is_split=True)
state_dict = load_state_dict(
shard_file, tp_actions if pre_tensor_parallel_split else None, expected_keys
shard_file, tp_actions if pre_tensor_parallel_split else None, expected_keys, ckpt_quant_stage=model.config.ckpt_quant_stage
)
error_msgs += _load_state_dict_into_model(lora_model.model, state_dict, "")
del state_dict
Expand Down
2 changes: 1 addition & 1 deletion paddlenlp/peft/prefix/prefix_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ def from_pretrained(
pre_tensor_parallel_split = True
tp_actions = prefix_model._get_tensor_parallel_convert_actions(is_split=True)
state_dict = load_state_dict(
shard_file, tp_actions if pre_tensor_parallel_split else None, expected_keys
shard_file, tp_actions if pre_tensor_parallel_split else None, expected_keys, ckpt_quant_stage=model.config.ckpt_quant_stage
)
error_msgs += _load_state_dict_into_model(prefix_model.prefix_encoder, state_dict, "")
del state_dict
Expand Down
Loading
Loading