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

Bugfix auto packing with streams + no remote path #1679

Merged
merged 5 commits into from
Dec 3, 2024

Conversation

mattyding
Copy link
Contributor

@mattyding mattyding commented Nov 30, 2024

This PR

Edge case where auto packing fails for a streaming dataset specified through streams field if only a local path and no remote path is provided. This configuration is more broadly supported for Foundry.

  train_loader:
    name: finetuning
    dataset:
      streams:
        finetuning:
          local: /foo/bar/train/mds/

An error is thrown in StreamingDataset init because there is a check that local contains an index file. The current auto packing script overwrites local with an empty tempdir. This fix temporarily has remote point to the user-provided local, which should contain an index file.

Testing

  • MCLI run with streams + no remote path
  • Added unit test

@mattyding mattyding requested a review from a team as a code owner November 30, 2024 04:45
@mattyding mattyding marked this pull request as draft November 30, 2024 05:36
@mattyding mattyding marked this pull request as ready for review November 30, 2024 05:37
tests/data/test_packing.py Outdated Show resolved Hide resolved
llmfoundry/data/packing.py Outdated Show resolved Hide resolved
@mattyding
Copy link
Contributor Author

Re-tested that it trains E2E with the following cases:

  • streams, local no remote
  • no streams, local == remote
  • no streams, remote only
  • no streams, local only

@mattyding mattyding requested a review from dakinggg December 3, 2024 02:14
Copy link
Collaborator

@dakinggg dakinggg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI failure looks unrelated, will have to figure that out separately

@mattyding mattyding enabled auto-merge (squash) December 3, 2024 18:29
@mattyding mattyding merged commit 16f92ef into main Dec 3, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants