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

rio-color 2.0 #92

Merged
merged 23 commits into from
Dec 17, 2024
Merged

rio-color 2.0 #92

merged 23 commits into from
Dec 17, 2024

Conversation

wboykinm
Copy link
Contributor

@wboykinm wboykinm commented Dec 13, 2024

Background

Here we find ourselves, years on from the last update to this excellent project by excellent people. Various forces have led to some neglect here, and in the interim we've had a great sort-of-fork by @vincentsarago: https://github.com/vincentsarago/color-operations - which has provided a continuation of the python API for color transformations. 🙏

However, it transpires that some of us still need the CLI, along with @perrygeo's optimize_color.py, and a few of the other peripherals provided by a baked-in rasterio dependency. As such, we are proposing a v2.0 of rio-color, with some important changes:

Updates

  • Remove python v2.x support
  • Remove python <v3.9 support
  • Bring rasterio up to v1.4
  • Bump everything else that's needed (cython, colormath, click, etc - thanks to Dependabot for pointing them out)
  • Remove TravisCI, go for GHA

Quirks

  • Unlike Vincent's fork, we appear to be pinned to numpy v1.2x for reasons I don't fully understand. Made it to v2.0.2!
  • Having just learned of the existence of appveyor, I may well be missing certain packaging combinations (python v3.12?)

I am greatly indebted to anyone who actually knows what they're doing and can point out the shortcomings in this PR. But for the moment, tests are green, appveyor is happy, and it might be possible to bring this toolset into 2025. What say y'all?

image

Landsat 8, Malargüe Argentina, under fresh snow, sigmoidal rgb 9 0.5 gamma b 4 gamma g 2, because we can.

dependabot bot and others added 17 commits December 2, 2024 19:53
Bumps [cython](https://github.com/cython/cython) from 0.29.32 to 3.0.11.
- [Release notes](https://github.com/cython/cython/releases)
- [Changelog](https://github.com/cython/cython/blob/master/CHANGES.rst)
- [Commits](cython/cython@0.29.32...3.0.11)

---
updated-dependencies:
- dependency-name: cython
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Updates the requirements on [pytest](https://github.com/pytest-dev/pytest) to permit the latest version.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst)
- [Commits](pytest-dev/pytest@3.10.0...8.3.4)

---
updated-dependencies:
- dependency-name: pytest
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <[email protected]>
Updates the requirements on [click](https://github.com/pallets/click) to permit the latest version.
- [Release notes](https://github.com/pallets/click/releases)
- [Changelog](https://github.com/pallets/click/blob/main/CHANGES.rst)
- [Commits](pallets/click@8.0.0...8.1.7)

---
updated-dependencies:
- dependency-name: click
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Bumps [colormath](https://github.com/gtaylor/python-colormath) from 2.0.2 to 3.0.0.
- [Release notes](https://github.com/gtaylor/python-colormath/releases)
- [Changelog](https://github.com/gtaylor/python-colormath/blob/master/CHANGES.txt)
- [Commits](gtaylor/python-colormath@2.0.2...3.0.0)

---
updated-dependencies:
- dependency-name: colormath
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Bumps [rasterio](https://github.com/rasterio/rasterio) from 1.1.8 to 1.4.3.
- [Release notes](https://github.com/rasterio/rasterio/releases)
- [Changelog](https://github.com/rasterio/rasterio/blob/main/CHANGES.txt)
- [Commits](rasterio/rasterio@1.1.8...1.4.3)

---
updated-dependencies:
- dependency-name: rasterio
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
@wboykinm wboykinm changed the title rio-color 2.x rio-color 2.0 Dec 16, 2024
@wboykinm wboykinm marked this pull request as ready for review December 16, 2024 19:15
@vincentsarago

This comment was marked as resolved.

Bump numpy to v2 because of python v3.9
@wboykinm
Copy link
Contributor Author

Unlike Vincent's fork, we appear to be pinned to numpy v1.2x for reasons I don't fully understand.

Looking at the appveyor logs it seems to be an issue with GCC (https://ci.appveyor.com/project/Mapbox/rio-color/builds/51159201/job/tkab8x7t9ts3elwa)

Problem encountered: NumPy requires GCC >= 8.4

Did you try numpy 2.0 after switching to python3.9 images in appveyor?

@vincentsarago You're a wizard. It's at numpy v2.0.2 now 🙏

@vincentsarago
Copy link
Contributor

🍪 or 12$

cc @jqtrde

@pratikyadav pratikyadav self-requested a review December 17, 2024 14:20
Copy link
Contributor

@pratikyadav pratikyadav left a comment

Choose a reason for hiding this comment

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

artworks-000170674962-zw1tfz-t1080x1080

@perrygeo
Copy link
Contributor

This thread feels like 2018 again 😄 rio-color lives on! Thanks for the bump 🙏 @wboykinm @pratikyadav

@wboykinm wboykinm merged commit 3ecc315 into master Dec 17, 2024
3 checks passed
@wboykinm wboykinm deleted the bill/future branch December 17, 2024 14:34
@wboykinm wboykinm mentioned this pull request Dec 17, 2024
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.

4 participants