-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
bugSomething isn't workingSomething isn't working
Description
If there's more than one file to upload, it's a tarball. If it's one file, it's not a tarball.
This is very confusing as an end-user of this data.
dotscience-python/dotscience/__init__.py
Lines 445 to 463 in 9c84cdd
| tar.close() | |
| def _upload_output_files(self): | |
| outputFileSize = len(self.currentRun.metadata()["output"]) | |
| if outputFileSize > 1: | |
| temp = tempfile.NamedTemporaryFile(delete=False) | |
| temp.close() | |
| # 1. Tar the files in the model dir | |
| self._tar_outputFiles(temp.name) | |
| # 2. Upload the tar | |
| # Uploading to the same model dir so we get proper paths | |
| # such as /model/assets/saved_model.json | |
| self._uploadArchive(temp.name, self.currentRun.getModelDir()) | |
| os.remove(temp.name) | |
| elif outputFileSize == 1: | |
| self._upload(self.currentRun.metadata()["output"][0]) | |
| print(".\n", end="") |
The more reasonable thing to do would be to always upload a tarball.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working