Changelog¶
All notable changes to Predspot are documented here. The format follows Keep a Changelog and the project uses Semantic Versioning.
[Unreleased]¶
[1.0.0] - 2026-09-14¶
First stable release and revival of the project: the code base now targets Python 3.10+ with current versions of pandas (>= 2.2), GeoPandas (>= 1.0), scikit-learn and statsmodels.
Added¶
crime_mapping.get_city_shape("Natal, RN, Brazil")— thin wrapper aroundosmnx.geocode_to_gdfreturning the raw city shape;osmnxis now a core dependency (theosmextra is kept, empty, for compatibility).examples/natal.ipynb: an executed end-to-end walkthrough on Natal with synthetic data (executed, with outputs), also rendered in the documentation.PredictionPipeline.evaluateaccepts a list of scorings and returns a DataFrame (one CV pass for all metrics).- README section explaining the framework (thesis, Chapter 3, Figures 7-12); the README is now the documentation home page.
crime_mapping.load_study_area("City, Country")fetches a study area boundary from OpenStreetMap viaosmnx(pip install predspot[osm]).synthetic.generate_crimesgenerates synthetic events inside any study area: Gaussian hotspots plus uniform background, with trend, annual cycle, day-of-week and hour-of-day patterns; reproducible withseed.QuadratCountmapping (event counts per cell) as a first-class alternative toKDE, usable with hexagonal (create_gridhexagonal) and square (create_gridsquares) grids insidePredictionPipeline.pipeline.build_default_pipelineand reproduciblepipeline.generate_testdata(..., seed=...).PredictionPipeline.features,.next_timeandrandom_state.- Test suite (pytest) and continuous integration for Python 3.10-3.13.
- Documentation rebuilt with MkDocs (Material + mkdocstrings), deployed automatically to GitHub Pages; replaces the Sphinx site.
pyproject.tomlpackaging (src layout) and automated PyPI publishing.
Changed¶
tfreqis optional in the feature classes (inferred from the series).- Debug
prints replaced with theloggingmodule (predspotlogger); thedebug=arguments were removed. - Wrapper estimators expose their inner estimator as
.estimator(previously._estimator). - Version jumps from 0.1.x to 1.0.0: the public API (
Dataset, mappings, feature classes,PredictionPipeline) is considered stable from here on. Datasetno longer modifies the input DataFrame and requires the study area to have a CRS.- Grid centroids are computed in a projected CRS; grids accept study areas in any CRS.
geojsoncontouris an optional dependency (pip install predspot[contour]).
Removed¶
- Sphinx documentation sources and the committed HTML build.
QuadratCount2,KGridand the hard dependencies ondescartes,contextilyandrtree.
Fixed¶
- Compatibility with pandas 2/3 (
'ME'offsets,DataFrame.append, positionalSeriesindexing), GeoPandas 1.x (sjoin(predicate=), CRS strings,gpd.datasets) and scikit-learn 1.x (FeatureUnioninternals). Seasonality/Trendnever calledSTL(...).fit().FeatureScalinghad nofit, so scalers inside aPipelinewere never fitted.
[0.1.3] - 2020¶
Original master's thesis release.