Skip to content

Commit

Permalink
Prepare for release v0.6.0
Browse files Browse the repository at this point in the history
  • Loading branch information
dirkgr committed Feb 25, 2022
1 parent f9da0af commit fbb7893
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## Unreleased

## [v0.6.0](https://github.com/allenai/tango/releases/tag/v0.6.0) - 2022-02-25

### Added

- New example that finetunes a pre-trained ResNet model on the Cats & Dogs dataset.
Expand Down
23 changes: 23 additions & 0 deletions tango/integrations/transformers/source_release.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import shutil
import tarfile
from pathlib import Path

from cached_path import cached_path, check_tarfile

from tango import Step


@Step.register("transformers_source_release")
class TransformersSourceRelease(Step[Path]):
VERSION = "001"
CACHEABLE = True

def run(self, hf_version: str = "4.9.2") -> Path: # type: ignore
url = f"https://github.com/huggingface/transformers/archive/refs/tags/v{hf_version}.tar.gz"
result = self.work_dir / "transformers"
if result.exists():
shutil.rmtree(result)
with tarfile.open(cached_path(url)) as tar_file:
check_tarfile(tar_file)
tar_file.extractall(result)
return result
2 changes: 1 addition & 1 deletion tango/version.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
_MAJOR = "0"
_MINOR = "5"
_MINOR = "6"
# On main and in a nightly release the patch should be one ahead of the last
# released build.
_PATCH = "0"
Expand Down

0 comments on commit fbb7893

Please sign in to comment.