# Uczenie maszynowe na danych przestrzennych

EN: **Spatial machine learning** · id `spatialml` · aliases: spatially explicit machine learning, spatial data science, geostatistical machine learning, uczenie przestrzenne, spatial ML

Path: [AI Atlas](https://aiatlasgraph.com/llms.txt) › [AI w obserwacji Ziemi i geoinformatyce](https://aiatlasgraph.com/t/geoai.md) › Uczenie maszynowe na danych przestrzennych

## Description

- PL: Metody uczenia maszynowego jawnie uwzględniające przestrzeń: walidacja przestrzenna, kodowanie położenia, modelowanie autokorelacji i niejednorodności przestrzennej oraz geolokalizacja.
- EN: Machine-learning methods that treat space explicitly: spatial validation, location encoding, modelling spatial autocorrelation and heterogeneity, and geolocalisation.

## In one sentence

- PL: Uczenie maszynowe, które bierze pod uwagę, że miejsca położone blisko siebie są podobne, a samo położenie niesie informację.
- EN: Machine learning that accounts for the fact that nearby places resemble each other and that location itself carries information.

## Problem it solves

- PL: Zwykłe modele traktują każdy punkt na mapie jak osobne losowanie, więc chwalą się dokładnością, której nie mają w nowych, odległych miejscach.
- EN: Ordinary models treat every point on a map as an independent draw, so they boast an accuracy they lack in new, distant places.

## What it does

- PL: Jak lokalny przewodnik, który wie, że sąsiednie ulice mają podobny charakter, ale nie udaje, że zna dzielnice, w których nigdy nie był.
- EN: Like a local guide who knows neighbouring streets share a character, but does not pretend to know districts never visited.

## Everyday example

- PL: Model cen mieszkań wypada świetnie w testach, a w nowym mieście bardzo się myli, bo sprawdzano go na sąsiadach mieszkań z treningu.
- EN: A flat-price model scores brilliantly in tests yet misses badly in a new city, because it was tested on neighbours of its training flats.

## This concerns you if you…

- PL: robisz mapy lub prognozy dla miejsc bez pomiarów
- PL: oceniasz model na danych z GPS-em lub adresami
- EN: make maps or forecasts for places without measurements
- EN: evaluate a model on data with GPS points or addresses

## Keywords

spatial autocorrelation · spatial cross-validation · area of applicability · location encoders · geographically weighted regression · kriging · spatial heterogeneity · CAST · blockCV · GeoAI

## How it works

- PL: Dane przestrzenne łamią założenie niezależnych próbek: pobliskie punkty mają podobne wartości i podobne błędy. Dlatego przy walidacji dzieli się je na bloki przestrzenne, zamienia współrzędne na cechy, które sieć potrafi wykorzystać, i sprawdza, gdzie model w ogóle wolno stosować.
- EN: Spatial data break the assumption of independent samples: nearby points share similar values and similar errors. So validation splits them into spatial blocks, coordinates are turned into features a network can use, and one checks where the model may be applied at all.

## Limits

- PL: Nie ma jednej właściwej wielkości bloku ani jednego najlepszego kodowania położenia; wybór zależy od celu mapy. Modele łatwo uczą się samego położenia zamiast zjawiska. Precyzyjne dane o miejscach niosą ryzyko dla prywatności.
- EN: There is no single right block size or best location encoding; the choice depends on the map's purpose. Models easily learn location itself instead of the phenomenon. Precise location data carry privacy risks.

## Key terms

- PL: **autokorelacja przestrzenna**: Bliskie miejsca mają podobne wartości, dalekie coraz mniej.
- PL: **obszar stosowalności**: Część mapy, gdzie dane wejściowe przypominają te z treningu.
- PL: **model jawnie przestrzenny**: Model, którego wynik zmienia się, gdy zjawisko przeniesiemy w inne miejsce.
- EN: **spatial autocorrelation**: Nearby places have similar values; distant ones less so.
- EN: **area of applicability**: The part of a map where inputs resemble the training data.
- EN: **spatially explicit model**: A model whose output changes if the phenomenon is moved elsewhere.

## Know first

- [Walidacja krzyżowa (Cross-validation)](https://aiatlasgraph.com/t/crossval.md)
- [Strategie podziału: losowy, czasowy, grupowy (Split strategies: random, temporal, grouped)](https://aiatlasgraph.com/t/splitstrategies.md)

## Subtopics (4 direct, 5 in total)

- [Kodowanie położenia geograficznego (Location encoding)](https://aiatlasgraph.com/t/locationencoding.md): Mapping a point's coordinates to a high-dimensional embedding (sinusoids, spherical harmonics, networks), often trained contrastively with satellite or ground images.
- [Ustalanie, gdzie zrobiono zdjęcie (Image geolocalisation)](https://aiatlasgraph.com/t/geolocalization.md): Predicting where on the planet a photo was taken: classification into geographic cells, retrieval from a location gallery, or contrastive image–GPS matching.
  - [Dopasowanie zdjęcia z ulicy do mapy satelitarnej (Cross-view geo-localisation)](https://aiatlasgraph.com/t/crossviewgeo.md): Retrieving and metrically localising a ground-level image by matching it against georeferenced aerial or satellite imagery.
- [Uzupełnianie mapy między punktami pomiarowymi (Spatial interpolation with machine learning and geostatistics)](https://aiatlasgraph.com/t/spatialinterpolation.md): Predicting a continuous variable at unsampled locations via kriging, machine-learning models with spatial features, or a combination.
- [Walidacja przestrzenna (bloki zamiast losowania) (Spatial cross-validation)](https://aiatlasgraph.com/t/spatialcv.md): Splitting data into test folds by spatial blocks, buffers or distance to estimate model error under spatial autocorrelation and extrapolation.

## Sources

- [Handbook of Geospatial Artificial Intelligence](<https://www.acsu.buffalo.edu/~yhu42/papers/2023_GeoAIHandbook_Preview.pdf>) `gao-hu-li-geoai-handbook-2023` · by Song Gao, Yingjie Hu, Wenwen Li (red.)
- [GeoAI: spatially explicit artificial intelligence techniques for geographic knowledge discovery and beyond](<https://people.geog.ucsb.edu/~jano/GeoAI_editorial_19.pdf>) `janowicz-geoai-2020` · by Krzysztof Janowicz, Song Gao, Grant McKenzie, Yingjie Hu, Budhendra Bhaduri
- [Spatial validation reveals poor predictive performance of large-scale ecological mapping models](<https://www.nature.com/articles/s41467-020-18321-y>) `ploton-spatial-validation-2020` · by Pierre Ploton, Frédéric Mortier, Maxime Réjou-Méchain, Nicolas Barbier, Nicolas Picard, et al.
- [Machine learning-based global maps of ecological variables and the challenge of assessing them](<https://www.nature.com/articles/s41467-022-29838-9>) `meyer-pebesma-global-maps-2022` · by Hanna Meyer, Edzer Pebesma

---

AI Atlas revision 122 (2026-10-30) · HTML: https://aiatlasgraph.com/t/spatialml · index: https://aiatlasgraph.com/llms.txt · everything: https://aiatlasgraph.com/llms-full.txt · updated 2026-10-30
