-
Notifications
You must be signed in to change notification settings - Fork 9.7k
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
Fix --split-max-size #6655
Fix --split-max-size #6655
Conversation
Byte size calculation was done on int and overflowed.
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.
Thanks, but we discussed in #6343 that taking into account the wide usage of this feature to cover it with tests to avoid reproduce it in the future.
I do not want to block this critical fix, but would you please include tests.sh and add it to the CI.
If you have not the time, I can do it later today.
Sure, I'll look into it now. |
Will autodiscover examples/*/tests.sh scripts and run them.
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.
Thanks. FYI @ngxson
Ok, done. :) I made some minor changes to tests.sh:
I've added autodiscovery of examples/*/tests.sh scripts (at that level only, so as not to include f.ex. examples/server/tests/tests.sh) to ci run. It will pass the bin and mnt/models directories as arguments. If you want to change how this works, I'm open to suggestions. |
Cool, the But yet to be supported. |
The change to However, for the test, I'm wondering:
|
To quote ci/README.md:
Which is what I did. :)
The longest part of the test is downloading the model the first time, the next longest part is running the model tests, but I tested it with CPU build, and it's not really that slow. |
IMO the goal of this test script is to test if your changes works before merging. However, what @phymbert It's up to you to decide if this behavior is expected or not.
CPU in CI machines can be different from personal machines. For that reason, the workflow of server example uses the small tinyllama model (less than 100MB in size). What I wanted to do earlier is to add the test and see if workflows in gitlab actions takes significantly longer to finish or not. But I couldn't find the output of the test from this PR, so I couldn't conclude. |
@ngxson Yeah, it is indeed a little strange, but according to the readme it's for exactly that purpose (not slowing down GHA)... Just had a cursory glance at the CI repo and it looks like it preloads its image with ggml-org/models:phi-2/ggml-model-f16.gguf which is 5GB, perhaps that would be better to test against? |
the It is OK if it is not run on all commits, we might ask any futur contributor to run it locally before merging. But better to request for an approval. |
I think the main problem is that we don't have the idea of running CI tests for That's just my personal thought, maybe @ggerganov will have other ideas. |
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.
For ggml-ci
we currently aim the runs to not take longer than 30 mins:
https://github.com/ggml-org/ci/blob/b2856375b21aa7d96bcc1d3a25d70f4446a0610d/env.sh#L113
Technically, this particular test does not need to run on more than one node since it does not reach any code that is hardware-dependent. But we can improve this in the future - let's merge like this for now
I think the main problem is that we don't have the idea of running CI tests for examples/* before this PR (except for server).
We can add instructions when opening a PR that reminds contributors to run the ggml-ci
CI locally
* Fix --split-max-size Byte size calculation was done on int and overflowed. * add tests.sh * add examples test scripts to ci run Will autodiscover examples/*/tests.sh scripts and run them. * move WORK_PATH to a subdirectory * clean up before and after test * explicitly define which scripts to run * add --split-max-size to readme
Byte size calculation was done on int and overflowed.
Fixes #6634
Fixes #6654