Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Recognising when you need a continuous value per pixel, not a class

The landing page introduced regression as predicting “how much” rather than “which class.” This page surveys where that fits in practice, and where classification or segmentation, covered in earlier lessons, remain the better choice.


1. Motivation

A continuous target forced into categorical bins loses information you often cannot recover later. Deciding early whether your project’s actual target is continuous, and whether you can realistically obtain reference data to train on, shapes everything from data preparation through evaluation in the rest of this lesson.


2. Core idea

Pixel-level regression fits when your target genuinely varies continuously across a landscape, and when the specific value, not just a category it falls into, is what your project needs. It requires reference data: measurements of the actual target quantity, paired with imagery, to learn from.


3. Where regression applies

A. Vegetation and index prediction

NDVI and other spectral indices can be predicted directly from multispectral imagery, useful for filling temporal gaps caused by cloud cover, or for harmonizing values across different sensors. This is the running case study for the rest of this lesson.

B. Structural and physical quantities

Canopy height, building height, and above-ground biomass are all physical quantities usually measured directly (LiDAR, field surveys) only in limited areas. A regression model trained on these direct measurements, paired with more widely available optical imagery, can produce wall-to-wall estimates across areas where direct measurement is unavailable, extending a geographically limited reference dataset much further.

C. Environmental and social quantities

Soil moisture, soil organic carbon, and population density are all continuous quantities that can be estimated from imagery combined with other spatial variables, supporting applications from precision agriculture to demographic analysis.

D. When other approaches are better

If your target genuinely has a small number of meaningful, distinct categories, and the exact value within a category adds little practical value, classification or segmentation (L05 and L07) are usually simpler and more directly interpretable. Land cover with a handful of well-defined classes is a good example: “forest” versus “cropland” is often more useful to a downstream user than a continuous greenness value, unless that specific continuous detail is what the project actually needs.


4. Python reactivation

No new Python here. This page is about scoping the target variable and confirming reference data exists, before the next page gets into how the modeling task itself changes.


5. Common pitfalls


6. Mini task

Your project estimates wildfire fuel load across a forested region. Would you frame this as classification, segmentation, or regression? What reference data would you need, and where might you realistically obtain it?

Sample solution

Fuel load is a continuous physical quantity (typically measured in mass per unit area), so regression is the natural framing, provided reference measurements are available. Realistic reference data sources include field plot measurements from forestry agencies, LiDAR-derived biomass estimates, or existing fuel-load models used by fire management agencies; the imagery (optical or radar) would then be paired with these reference values to train the regression model, the same overall pattern used for canopy height and biomass estimation.


7. Key takeaways

Further reading