Skip to content
This repository has been archived by the owner on Mar 21, 2024. It is now read-only.

Use PIL.PngImagePlugin to load pngs #588

Merged
merged 10 commits into from
Nov 19, 2021
Merged

Use PIL.PngImagePlugin to load pngs #588

merged 10 commits into from
Nov 19, 2021

Conversation

JonathanTripp
Copy link
Contributor

@JonathanTripp JonathanTripp commented Nov 15, 2021

Replace using SciPy with PIL.PngImagePlugin to load png files. SciPy does end up calling this plugin, but there's a lot of overhead.

Please follow the guidelines for PRs contained here. Checklist:

  • Ensure that your PR is small, and implements one change.
  • Add unit tests for all functions that you introduced or modified.
  • Run PyCharm's code cleanup tools on your Python files.
  • Link the correct GitHub issue for tracking.
  • Update the Changelog file: Describe your change in terms of
    Added/Changed/Removed/... in the "Upcoming" section.
  • When merging your PR, replace the default merge message with a description of your PR,
    and if needed a motivation why that change was required.

@JonathanTripp JonathanTripp self-assigned this Nov 15, 2021
@JonathanTripp JonathanTripp linked an issue Nov 15, 2021 that may be closed by this pull request
@JonathanTripp JonathanTripp changed the title Use matplotlib to load pngs Use PIL.PngImagePlugin to load pngs Nov 17, 2021
Copy link
Contributor

@ant0nsc ant0nsc left a comment

Choose a reason for hiding this comment

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

It's all correct - but your test does not test load_image, but a re-write of it.

Tests/ML/utils/test_io_util.py Outdated Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
@JonathanTripp JonathanTripp merged commit b96afc3 into main Nov 19, 2021
@JonathanTripp JonathanTripp deleted the jontri/png_load branch November 19, 2021 10:08
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Speed up png image file loading
3 participants