-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Fixed point integer resample #1881
Conversation
What are the units on the performance measurement? |
Megapixels of source image per second. This is testing script: https://gist.github.com/homm/f9b8d8a84a57a7e51f9c2a5828e40e63
|
I split New tests really good, because they check the consistency of result after manipulations: there should not be any shifts or dithering. And just for information, none of new tests are passed on master:
With the latest changes (separate Could anyone help me with AppVeyor windows builds? Error message |
I'll see what I can do on the windows builds. Probably a compile error, and for some reason we're not getting the traces. The usual compile error is from a declaration not being at the beginning of a block, but I'm not seeing that from a quick scan of the diff. |
Error appears to be this: https://ci.appveyor.com/project/wiredfool/pillow/build/3.3.pre.290/job/n525alym7ebxiips#L1369
|
If you rebase, you'll get the appveyor changes. |
ok, I'll check what we can use in Visual C |
Changes Unknown when pulling b04e736 on uploadcare:fpi-resample into * on python-pillow:master*. |
Changes Unknown when pulling c23e897 on uploadcare:fpi-resample into * on python-pillow:master*. |
Changes Unknown when pulling 0da1564 on uploadcare:fpi-resample into * on python-pillow:master*. |
Changes Unknown when pulling 233bbb6 on uploadcare:fpi-resample into * on python-pillow:master*. |
Changes Unknown when pulling 8ca0a5d on uploadcare:fpi-resample into * on python-pillow:master*. |
LOL, new problems with windows: build hangs up on I'm ok with all other changes. |
Changes Unknown when pulling aaf51e4 on uploadcare:fpi-resample into * on python-pillow:master*. |
@wiredfool Any thoughts about win builds? |
I'll take a look, bot probably not tonight. |
Looks like it's this test: https://github.com/python-pillow/Pillow/blob/master/Tests/test_image_filter.py#L39 that is hanging. See: https://ci.appveyor.com/project/wiredfool/pillow/build/3.3.pre.295/job/wq9ms96g7w1amjvy The code to change the way the tests run is in wiredfool@55b2c3b, which I'm planning to pr/commit shortly. |
I found out that the problem is in replacing |
Changes Unknown when pulling 757a728 on uploadcare:fpi-resample into * on python-pillow:master*. |
Returning |
return (Imaging) ImagingError_MemoryError(); | ||
} | ||
|
||
kk = malloc(xsize * kmax * sizeof(int)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to check this against INT_MAX for overflow. Also probably convert to calloc.
fix windows build
@wiredfool Done. Also rebased against master to pass the latest resampling accuracy tests. |
This change speeds up resampling up to 60% and eliminates ugly
i2f
hack.I'll add tests for other modes and maybe return old implementation for
IMAGING_TYPE_INT32
andIMAGING_TYPE_FLOAT32
.