On the Selection and Effectiveness of Pseudo-Absences for Species Distribution Modeling with Deep Learning

Robin Zbinden, Nina van Tiel, Benjamin Kellenberger, Lloyd Haydn Hughes, Devis Tuia

TL;DR

This paper tackles a critical challenge in species distribution modeling: how to effectively use presence-only data with deep learning. They introduce a novel, flexible loss function that intelligently incorporates different types of "pseudo-absences" (inferred absences) and accounts for species-specific data imbalances, leading to more accurate ecological predictions.

What Problem Does This Paper Address?

Species distribution models (SDMs) are vital for understanding and conserving biodiversity, helping us predict where species might live based on environmental factors. However, a major hurdle is the common availability of "presence-only" data – we know where a species was seen, but rarely where it wasn't. This makes it hard for machine learning models, which typically need both positive (presence) and negative (absence) examples to learn effectively.

To bridge this gap, researchers often create "pseudo-absences" by designating random locations as negative samples. But this isn't straightforward. There are different ways to choose these pseudo-absences (e.g., random points vs. points where other species are found), and they can introduce biases. Furthermore, the sheer imbalance between the few presences and many pseudo-absences can confuse models, especially when dealing with multiple species simultaneously using deep learning. This paper aims to provide a robust solution for integrating these pseudo-absences into deep learning-based multi-species SDMs, addressing class imbalance and the choice of pseudo-absence types.

Methods

The core of this paper is a novel "full weighted loss function" designed for multi-species deep learning models. This function builds upon existing approaches by introducing several key innovations:

  • Species Weights ($w_s$): To combat the issue of "long-tailed" distributions (where some species have many observations and others very few), each species is assigned a weight inversely proportional to its frequency. This ensures that species with fewer presences aren't drowned out by those with many.
  • Presence Weight ($\lambda_1$): This parameter allows for adjusting the emphasis on correctly classifying presences versus pseudo-absences. A higher $\lambda_1$ prioritizes accurate presence predictions.
  • Pseudo-Absence Weight ($\lambda_2$): This crucial parameter controls the balance between two types of pseudo-absences: "target-group background points" (presences of other species) and "random background points" (randomly sampled locations). This allows the model to leverage the strengths of both, with $\lambda_2=1$ favoring target-group points and $\lambda_2=0$ favoring random points.
  • Spatial Block Cross-Validation: To tune the optimal values of $\lambda_1$ and $\lambda_2$, the authors employ spatial block cross-validation. This method spatially partitions the data, ensuring that the model is tested on geographically distinct areas from where it was trained, which is critical for assessing generalization ability in ecological modeling.

Datasets

The study utilizes the benchmark dataset from Elith et al. (2020). This dataset comprises presence-only data for 226 anonymized species across six diverse regions: Australian Wet Tropics (AWT), Canada (CAN), New South Wales (NSW), New Zealand (NZ), South America (SA), and Switzerland (SWI). For evaluation, the dataset provides full presence-absence data. This dataset is well-established and has been used in previous SDM studies, making it a suitable benchmark for comparing different approaches.

Key Insights and Ideas

  • Pseudo-Absence Choice Matters: The study confirms that the type of pseudo-absence used significantly impacts model performance. Target-group background points generally outperform random background points, especially in areas with sampling bias.
  • Balancing Act is Key: The proposed weighted loss function is not just about using pseudo-absences, but about how they are used. The ability to dynamically weight different types of pseudo-absences and account for species imbalance is crucial for robust predictions.
  • Data-Driven Tuning is Essential: The optimal settings for the weighting parameters ($\lambda_1$, $\lambda_2$) are not universal. They are data-dependent and require careful tuning using methods like spatial block cross-validation to achieve the best results for specific regions and species.
  • Deep Learning for Multi-Species is Promising: The research demonstrates that deep learning, when equipped with appropriate loss functions, can effectively handle the complexity of multi-species distribution modeling, offering a more unified approach than training individual models for each species.

Key Results

  • The proposed full weighted loss function consistently outperformed existing loss functions from Cole et al. (2023) across most regions, achieving higher mean AUC scores.
  • The optimal pseudo-absence weight ($\lambda_2$) varied by region, highlighting the need for data-specific tuning. For instance, regions with higher sampling bias benefited more from target-group background points.
  • Incorporating species weights ($w_s$) significantly improved performance, particularly for species with fewer presence records, effectively addressing class imbalance.
  • The authors' models achieved performance comparable to single-species models like Maxent, while offering the advantage of a single model per region. For example, the average AUC across all regions was 0.755 with the fine-tuned weighted loss.

Limitations and Future Work

  • Tabular Data Limitations: The study acknowledges that the tabular format of the Elith et al. (2020) dataset may limit the performance of neural networks compared to approaches that can leverage richer data types.
  • Generalizability to Other Architectures: The authors plan to investigate whether their weighted loss function's effectiveness extends to other neural network architectures, such as convolutional neural networks or Transformers, and to datasets with diverse data types (e.g., environmental rasters, satellite images).
  • Species-Specific $\lambda_2$: Future work could explore setting distinct pseudo-absence weights ($\lambda_2$) for individual species within the same region, as different species may respond differently to pseudo-absence types.
  • Selective Sampling of Random Background Points: The loss function allows for flexible inclusion of random background points, and future research could explore optimal strategies for selectively sampling these points from specific subareas.

Summary updated

BibTeX
@inproceedings{zbinden2025selection,
  author = {Robin Zbinden and Nina van Tiel and Benjamin Kellenberger and Lloyd Haydn Hughes and Devis Tuia},
  title = {{On the Selection and Effectiveness of Pseudo-Absences for Species Distribution Modeling with Deep Learning}},
  booktitle = {Ecological Informatics},
  year = {2025},
  url = {https://openreview.net/forum?id=3sXB2cPa0n},
}
Figure