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

Add support for Databricks File System backend #362

Merged
merged 11 commits into from
Aug 23, 2023

Conversation

maddiedawson
Copy link
Contributor

@maddiedawson maddiedawson commented Aug 4, 2023

Description of changes:

Add support for uploading data to and downloading data from Databricks File System (DBFS)

Issue #, if available:

STR-128

Merge Checklist:

Put an x without space in the boxes that apply. If you are unsure about any checklist, please don't hesitate to ask. We are here to help! This is simply a reminder of what we are going to look for before merging your pull request.

General

  • I have read the contributor guidelines
  • This is a documentation change or typo fix. If so, skip the rest of this checklist.
  • I certify that the changes I am introducing will be backward compatible, and I have discussed concerns about this, if any, with the MosaicML team.
  • I have updated any necessary documentation, including README and API docs (if appropriate).

Tests

  • I ran pre-commit on my change. (check out the pre-commit section of prerequisites)
  • I have added tests that prove my fix is effective or that my feature works (if appropriate).
  • I ran the tests locally to make sure it pass. (check out testing)
  • I have added unit and/or integration tests as appropriate to ensure backward compatibility of the changes.

Copy link
Collaborator

@karan6181 karan6181 left a comment

Choose a reason for hiding this comment

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

Thanks for doing this. Few minor comments:

  • How does the dbfs authentication happens? I think it might be related to the UC Volume PR that you have created ?
  • Can you also add the similar functionality in upload.py which basically uploads the shard files in UC during dataset conversion? You can look at PR 311 and 265 for reference.
  • Can you also add a unit test for the same in test_download.py and test_upload.py ?
  • Can you also update the documentation with UC Volume section on how user would provide a credentials ?

Thanks!

streaming/base/storage/download.py Show resolved Hide resolved
@maddiedawson
Copy link
Contributor Author

Thanks for doing this. Few minor comments:

  • How does the dbfs authentication happens? I think it might be related to the UC Volume PR that you have created ?

I added some details to the docs; users will set DATABRICKS_HOST and DATABRICKS_TOKEN.

  • Can you also add the similar functionality in upload.py which basically uploads the shard files in UC during dataset conversion? You can look at PR 311 and 265 for reference.

Done

Done

  • Can you also update the documentation with UC Volume section on how user would provide a credentials ?

Done

Thanks!

streaming/base/storage/download.py Outdated Show resolved Hide resolved
streaming/base/storage/upload.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@karan6181 karan6181 left a comment

Choose a reason for hiding this comment

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

For CI test failure, you can change this line to "[all]" which will install all the extra dependency packages.

@maddiedawson
Copy link
Contributor Author

For CI test failure, you can change this line to "[all]" which will install all the extra dependency packages.

Done

@karan6181
Copy link
Collaborator

For the lint failure, Can you please add the below lines in this file ? I have verified it and now the lint will pass.

# Disable checks for missing imports, as a conditional install of streaming will not include them
# Any incorrect imports will be discovered through test cases
reportMissingImports="none"

@karan6181 karan6181 changed the title Add support for downloading from dbfs Add support for Databricks File System backend Aug 23, 2023
@maddiedawson
Copy link
Contributor Author

For the lint failure, Can you please add the below lines in this file ? I have verified it and now the lint will pass.

# Disable checks for missing imports, as a conditional install of streaming will not include them
# Any incorrect imports will be discovered through test cases
reportMissingImports="none"

Done

@karan6181 karan6181 enabled auto-merge (squash) August 23, 2023 17:01
@karan6181 karan6181 merged commit f402379 into mosaicml:main Aug 23, 2023
5 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