Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/test-cloud/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ runs:
using: "composite"
steps:
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
uses: aws-actions/configure-aws-credentials@v5
with:
role-to-assume: arn:aws:iam::369469875935:role/AutoGluonCloudCIRole
role-duration-seconds: 7200
Expand Down
40 changes: 0 additions & 40 deletions .github/workflow_scripts/env_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,43 +14,3 @@ function install_cloud_test {
python3 -m pip install --upgrade pytest-forked
python3 -m pip install --upgrade -e ./[tests]
}

function install_latest_tabular_and_multimodal_dependencies {
git clone https://github.com/autogluon/autogluon.git
python3 -m pip install -e autogluon/common/
python3 -m pip install -e autogluon/core/[all]
python3 -m pip install -e autogluon/features/
}

function install_latest_tabular {
install_latest_tabular_and_multimodal_dependencies
python3 -m pip install -e autogluon/tabular/[all]
}

function install_latest_multimodal {
install_latest_tabular_and_multimodal_dependencies
python3 -m pip install -e autogluon/multimodal/
mim install mmcv-full --timeout 60
python3 -m pip install --upgrade "mmdet>=2.28, <3.0.0"
python3 -m pip install --upgrade "mmocr<1.0"
}

function install_tabular {
VERSION=$1
if [ $VERSION = "source" ]
then
install_latest_tabular
else
python3 -m pip install -U autogluon.tabular==$1
fi
}

function install_multimodal {
VERSION=$1
if [ $VERSION = "source" ]
then
install_latest_multimodal
else
python3 -m pip install -U autogluon.multimodal==$1
fi
}
8 changes: 0 additions & 8 deletions .github/workflow_scripts/test_cloud.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@ set -ex

source $(dirname "$0")/env_setup.sh

if [ $MODULE = "tabular" ]
then
install_tabular $AG_VERSION
elif [ $MODULE = "multimodal" ]
then
install_multimodal $AG_VERSION
fi

install_cloud_test

python3 -m pytest -n 4 --junitxml=results.xml tests/unittests/$MODULE/ --framework_version $AG_VERSION
55 changes: 0 additions & 55 deletions .github/workflows/continuous_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ on:
branches:
- master
- stable
- dev
tags:
- 'v*'
pull_request:
Expand Down Expand Up @@ -109,60 +108,6 @@ jobs:
with:
submodule-to-test: tabular
ag_version: '${{ matrix.AG_VERSION }}'
test_text_cloud:
if: false
strategy:
fail-fast: false
matrix:
AG_VERSION: ["source", "1.2.0"]
needs: cloud_lint_check
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v5
- uses: actions/setup-python@v6
with:
python-version: '3.11'
- name: Check if changes beside docs
uses: dorny/paths-filter@v3
id: changes
with:
filters: |
other_than_docs:
- '!(docs/**)**'
- name: Test Text Cloud
if: steps.changes.outputs.other_than_docs == 'true'
uses: ./.github/actions/test-cloud
with:
submodule-to-test: text
ag_version: '${{ matrix.AG_VERSION }}'
test_image_cloud:
if: false
strategy:
fail-fast: false
matrix:
AG_VERSION: ["source", "1.2.0"]
needs: cloud_lint_check
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v5
- uses: actions/setup-python@v6
with:
python-version: '3.11'
- name: Check if changes beside docs
uses: dorny/paths-filter@v3
id: changes
with:
filters: |
other_than_docs:
- '!(docs/**)**'
- name: Test Image Cloud
if: steps.changes.outputs.other_than_docs == 'true'
uses: ./.github/actions/test-cloud
with:
submodule-to-test: image
ag_version: '${{ matrix.AG_VERSION }}'
test_multimodal_cloud:
if: false
strategy:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pypi_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build twine pypandoc packaging
pip install build twine
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets. PYPI_USERNAME }}
Expand Down
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
Expand Down Expand Up @@ -130,7 +129,6 @@ dmypy.json
.pyre/

src/autogluon/cloud/version.py
VERSION.minor
.idea
.vscode
.DS_Store
Expand Down
21 changes: 0 additions & 21 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,7 @@ per-file-ignores = {"*/__init__.py" = ["F401"]}
[tool.ruff.lint.isort]
known-first-party = ["autogluon"]

[tool.mypy]
warn_unused_configs = true
show_error_context = true
pretty = true
check_untyped_defs = true

[tool.pytest.ini_options]
testpaths = ["tests"]
addopts = "--strict-markers"
xfail_strict = true

[tool.coverage.run]
source = ["autogluon.cloud"]
branch = true

[tool.coverage.report]
show_missing = true
skip_covered = true
fail_under = 80

[tool.coverage.paths]
source = [
"src/autogluon/cloud",
"*/site-packages/autogluon/cloud",
]
34 changes: 7 additions & 27 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,29 +16,13 @@ def create_version_file(*, version):
f.write("__version__ = '{}'\n".format(version))


def update_version(version, use_file_if_exists=True, create_file=False):
def update_version(version):
"""
To release a new stable version on PyPi, simply tag the release on github, and the Github CI will automatically publish
a new stable version to PyPi using the configurations in .github/workflows/pypi_release.yml .
You need to increase the version number after stable release, so that the nightly pypi can work properly.
To release a new stable version on PyPi, tag the release on github; the Github CI publishes it to PyPi
(see .github/workflows/pypi_release.yml, which sets RELEASE=1). Non-release builds get a `.dev0` suffix.
"""
try:
if not os.getenv("RELEASE"):
from datetime import date

minor_version_file_path = "VERSION.minor"
if use_file_if_exists and os.path.isfile(minor_version_file_path):
with open(minor_version_file_path) as f:
day = f.read().strip()
else:
today = date.today()
day = today.strftime("b%Y%m%d")
version += day
except Exception:
pass
if create_file and not os.getenv("RELEASE"):
with open("VERSION.minor", "w") as f:
f.write(day)
if not os.getenv("RELEASE"):
version += ".dev0"
return version


Expand Down Expand Up @@ -105,7 +89,7 @@ def default_setup_args(*, version):


version = "0.5.1"
version = update_version(version, use_file_if_exists=False, create_file=True)
version = update_version(version)

install_requires = [
# common module provides utils with stable api across minor version
Expand Down Expand Up @@ -133,14 +117,10 @@ def default_setup_args(*, version):
extras_require["all"] = all_requires

test_requirements = [
"tox",
"pytest",
"pytest-cov",
"moto",
"autogluon.common>=0.7",
] # Install pre-release of common for testing

test_requirements = list(set(test_requirements))
]
extras_require["tests"] = test_requirements

if __name__ == "__main__":
Expand Down
Loading