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

Fixes #3,#11,#12,#15 resolves #2,#14,#23 couple of perfomance tweaks #20

Open
wants to merge 38 commits into
base: master
Choose a base branch
from

Conversation

kwauchope
Copy link

Adds python3 support from #23 and based on work from @mpern . All changes backwards compatible with 2.6 and 2.7. Added Travis builds for 2.6,2.7,3.2,3.3,3.4

Added different data type support such as an already flattened array to save processing and more flexibility while not breaking backwards compatibility. Valid point inputs now include flat, array of arrays, array of tuples, tuples of tuples and tuple of arrays. Internally stores everything in a flat array.

Added weight functionality to resolve #14. Weight functionality is optional for backwards compatibility. Expects arrays or tuples with 3 values or every 3rd point in a flat array to be a weight between 0 and 1.

Added ability to specify source and destination epsg for multiple projection support to resolve #2 . Is an optional install (heatmap[proj]) that requires pyproj. With this addition the output can be used for mercator maps and such as well as transforming coordinate systems such as WGS84 to World Equidistant Cylindrical for more accurate KML overlays.

Fixes #12 by optionally using setuptools if available. Cleaned up so #11 is fixed as well.

Fixes #3 and #15 due to mixup of east/west in saveKML.

Put in a test to break early from the density calculations when dist>radius. Stops the contribution of a point to pixels outside of it's radius, an extreme version of this is possibility of having very visible squares in the heatmap depending on radius and pixVal calculation constants. After some quick profiling also reduced processing time by almost 20% which makes sense due to the main loop being reduced by a factor of pi/4 and if the branch predictor is getting it right more often than not. This is significant for large dot sizes and data sets.

kwauchope and others added 4 commits May 3, 2014 01:15
Put in a test to break early from the density calculations when dist>radius. Stops the contribution of a point to pixels outside of it's radius, an extreme version of this is possibility of having very visible squares in the heatmap depending on radius and pixVal calculation constants.
Fix pip install error
@kwauchope kwauchope closed this Aug 1, 2014
@kwauchope kwauchope changed the title Stop points bleeding into pixels outside of radius Fixes #12, resolves #14, couple of perfomance tweaks Aug 1, 2014
@kwauchope kwauchope reopened this Aug 1, 2014
@kwauchope kwauchope changed the title Fixes #12, resolves #14, couple of perfomance tweaks Fixes #11,#12, resolves #14, couple of perfomance tweaks Aug 2, 2014
@kwauchope kwauchope changed the title Fixes #11,#12, resolves #14, couple of perfomance tweaks Fixes #12, resolves #14, couple of perfomance tweaks Aug 2, 2014
@kwauchope kwauchope changed the title Fixes #12, resolves #14, couple of perfomance tweaks Fixes #12,#3,#15 resolves #14, couple of perfomance tweaks Aug 3, 2014
@kwauchope kwauchope changed the title Fixes #12,#3,#15 resolves #14, couple of perfomance tweaks Fixes #3,#11,#12,#15 resolves #2,#14, couple of perfomance tweaks Aug 4, 2014
from PIL import Image

use_pyproj = False
Copy link
Author

Choose a reason for hiding this comment

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

Optional Import of pyproj

@kwauchope kwauchope changed the title Fixes #3,#11,#12,#15 resolves #2,#14, couple of perfomance tweaks Fixes #3,#11,#12,#15 resolves #2,#14,#23 couple of perfomance tweaks Aug 22, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant