-
Notifications
You must be signed in to change notification settings - Fork 4
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
Sync eval changes in OLMo/ladder-1xC to here #122
Conversation
src/olmo_core/internal/common.py
Outdated
# install ai2-olmo-eval from source git repo | ||
"pip uninstall -y ai2-olmo-eval", | ||
"pip install git+https://github.com/allenai/OLMo-in-loop-evals.git@moreeval", |
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.
will clean this up when the PR in olmo-eval lands
shuffle=False, | ||
num_replicas=get_world_size(dp_process_group), | ||
rank=get_rank(dp_process_group), | ||
) | ||
|
||
rank_batch_size_instances = max(0, rank_batch_size // self.task.max_sequence_length) |
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 causes a bug. I don't see why we should divide batch size by seq len. Batch size was already number of examples.
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.
Batch size was already number of examples.
Where was it set to number of examples instead of tokens? It should always be set in tokens. This change will cause bugs elsewhere
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.
It's derived from Line 230 of this file, eval_batch_size
. Do you mean this variable should be in number of tokens? It seems to be a semantic change from the old repo, and each eval's max seq length is dependent on the task so we can't set a fixed batch size ...
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.
It is a change from the old repo.
each eval's max seq length is dependent on the task so we can't set a fixed batch size
Well batch size is roughly fixed by number of tokens, not instances. This is more efficient because we can pack more instances from shorter tasks together.
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.
Got it. I've reverted it so now eval_batch_size
takes number of tokens.
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.
One minor comment, otherwise LGTM!
src/scripts/train/OLMo2-1B.py
Outdated
@@ -73,6 +76,48 @@ def build_trainer_config(common: CommonComponents) -> TrainerConfig: | |||
cancel_check_interval=10, | |||
), | |||
) | |||
.with_callback( | |||
"downstream", |
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.
Let's call this "downstream_evaluator" to be consistent with the naming convention for other callbacks.
"downstream", | |
"downstream_evaluator", |
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, fixed
This adds scaling law eval sets as in-loop.
Testing of metric: https://legacy.beaker.org/ex/01JF4NNA49YJGC55P3Q5FPEAPA/tasks/01JF4NNA4HM9Q90BQNQ99XSJ9Y/job/01JF4P6XRZVTDXWC3J2559R0K5
To see things in Comet: https://www.comet.com/ai2/olmo-core-1b/7a3614872861484dbc7ad651ad5c9e35