-
Notifications
You must be signed in to change notification settings - Fork 961
[WIP]Support ray #6245
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
Closed
Closed
[WIP]Support ray #6245
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
4bcdc67
wip
tastelikefeet 1cac35e
wip
tastelikefeet 053b622
wip
tastelikefeet cf65f67
wip
tastelikefeet 6a881dd
wip
e219a61
fix
263adc2
fix
14750b3
fix
b50fb98
Merge branch 'main' into feat/ray-1
tastelikefeet 7ac3224
wip
tastelikefeet b20a09d
wip
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| swift sample --config sampling.yaml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| ray_exp_name: sampling | ||
|
|
||
| use_ray: true | ||
|
|
||
| model: Qwen/Qwen2.5-VL-3B-Instruct | ||
| dataset: tastelikefeet/competition_math#16 | ||
| num_return_sequences: 2 | ||
| max_length: 2048 | ||
| system: "You are a math model, you should **think step by step** carefully, and always consider the basic math principles to avoid making calculating mistakes. Give the final answer wrapped with \\boxed{{}}" | ||
| load_args: false | ||
| sampler_engine: vllm | ||
| max_new_tokens: 768 | ||
| orm_model: math | ||
| prm_model: Qwen/Qwen2.5-Math-PRM-7B | ||
| override_exist_file: true | ||
| num_sampling_per_gpu_batch_size: 4 | ||
| top_p: 1.0 | ||
| temperature: 1.0 | ||
| prm_threshold: 0.8 | ||
| output_file: sampling.jsonl | ||
| engine_kwargs: "{\"mm_processor_cache_gb\":0.0}" | ||
|
|
||
| device_groups: | ||
| nproc_per_node: 4 | ||
| sample_group: | ||
| device: GPU | ||
| ranks: list(range(0, 2)) | ||
| workers: | ||
| - sampler | ||
| rm_group: | ||
| device: GPU | ||
| ranks: list(range(2, 4)) | ||
| workers: | ||
| - prm | ||
| - orm |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -27,6 +27,7 @@ requests | |
| rouge | ||
| safetensors | ||
| scipy | ||
| omegaconf | ||
| sentencepiece | ||
| simplejson>=3.3.0 | ||
| sortedcontainers>=1.5.9 | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ray |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This loop iterates through
argv[1:], but accesses elements usingargv[i]andargv[i + 1]. This will cause anIndexErrorwheniis the last index in the loop, asargv[i + 1]will be out of bounds. The loop should iterate through the indices ofargvdirectly.To fix this, iterate through
range(1, len(argv), 2)and adjust the indexing accordingly.