The Spanish Government Tackles Wildfires Through ML and AI Running on AWS

Executive Summary

Spain predicts the outbreaks of wildfires with 80 percent accuracy using machine learning (ML) and artificial intelligence services running on AWS. Responsibility for wildfire control and data collection belongs to the Ministry for Ecological Transition and the Demographic Challenge, with data on the conflagrations provided by the Ministry of Agriculture, Fisheries and Food, also responsible for developing computer applications that extract value from data. The solution uses Amazon SageMaker for ML modelling with AWS Lambda functions, AWS Glue, and Amazon Athena helping transform raw data.

A Shared Battle to Protect the Environment

Among the Spanish government’s 22 ministerial departments, two share a major commitment to the development and protection of rural areas. The Ministry for Ecological Transition and the Demographic Challenge (MITECO) works to protect the country’s natural heritage, including its biodiversity and forests. The Ministry of Agriculture, Fisheries and Food (MAPA) carries out government policy in areas affecting agriculture, livestock, and the economic well-being of local communities. The concerns of both ministries coincided over an urgent need to tackle wildfires across the country. In 2019, these blazes claimed approximately 81,000 hectares throughout Spain, with local authorities reporting more than 10,000 outbreaks.

“We wanted to use technology to assess the multiple elements, including socio-economic factors, that affect the number of wildfires.” 

- Faustino Sánchez, Head of Data Analysis, Ministry of Agriculture, Fisheries and Food

Applying Science to Reduce the Damage

Given the destructive power of the conflagrations, predicting the start of wildfires is crucially important. Knowing where and when one is likely to strike provides firefighters valuable time to plan and anticipate their actions, by creating firebreaks for instance, to contain any blaze. However, predicting wildfires with accuracy has historically been a challenge. In fact, the process in Spain relied heavily on the experience and intuition of the MITECO personnel and the regional administration in control of wildfire monitoring. The race was on to find a more scientific way to calculate wildfire strikes. The plan was to use machine learning (ML) and artificial intelligence (AI) techniques, extracting insight from multiple data sources using algorithms, as the basis for highly accurate forecasts. “We wanted to use technology to assess the multiple elements, including socio-economic factors, that affect the number of wildfires,” says Faustino Sánchez, Head of Data Analysis at the Ministry of Agriculture, Fisheries and Food.

Adding ML and AI in the Cloud to the Taskforce

MAPA began discussions to find a cloud service and IT partner to help complete the project, called Arbaria. Sánchez explains, “Once we’d finalized working with Amazon Web Services and DXC, an AWS Partner offering consulting services, we were good to get Arbaria running on the cloud.” The goal had always been to run Arbaria on the cloud because of the scalable data processing and storage capacity available. Nonetheless, MAPA specifically looked to work with AWS because of the “flexibility of the tools that AWS had to offer.” Sánchez continues, “The serverless part of AWS was a very powerful proposition. It would enable us to simply focus on our ML models.” Despite it being the first time Sánchez and his colleagues had used AWS, the learning process was quick. Explains Sánchez, “AWS was very supportive, helping us to design the cloud architecture, including the AWS services.” After confirmation of the core architecture, DXC then worked on designing the continuous integration and continuous delivery pipeline to help developers deliver code changes frequently and reliably. Adds Sánchez, “Thanks to DXC, we also gained templates to automate much of the build and deployment processes. This was particularly crucial because we’re only a small team.”

Cleaning the Data, Extracting Predictions

Of the many AWS services supporting the Arbaria cloud infrastructure, a few stand out. For instance, Amazon SageMaker allows data scientists to prepare, build, train, and deploy the ML models to generate real-time predictions for wildfires. Amazon Simple Storage Service (Amazon S3) provides a low-cost depository to store data for those predictions from ten different sources. Furthermore, AWS Lambda serverless functions trigger AWS Glue, a serverless data integration service, to catalog the raw data and Amazon Athena, an interactive query service, stores and retrieves the information for the ML models to query. Says Sánchez, “The raw data is widely dispersed. For example, the demographic data is in the National Institute of Statistics, the meteorological data is in the State Meteorological Agency (AEMET), and the unemployment data is in the Public State Employment Service (SEPE). The data is very heterogeneous, but with AWS we can homogenize it all and get fast and accurate results from our ML models.”

Identifying Conflagrations with 80 Percent Accuracy

As a result of Arbaria running on AWS, wildfire predictions are significantly more accurate, allowing MITECO valuable time to coordinate responses. During tests using historical data, there was an 80 percent correlation between the time and location of wildfires and Arbaria’s predictions. According to Sánchez, the MITECO unit, which started using the AWS infrastructure in 2020, is extremely satisfied. “They came back and said how very useful it’d been and how close the predictions were,” he says. The simplicity and scalability of the AWS infrastructure means a small team is managing the entire solution. Furthermore, its flexibility and low cost of ownership is allowing the team to apply its predictive capabilities to other areas. For example, by scaling the infrastructure to support a project called Fruktia, which will use the ML models to predict fruit crops. “The beauty of our AWS solution is that we can take it and apply it to many more projects related to the rural and marine environment,” concludes Sánchez.

The Ministry of Agriculture, Fisheries and Food

About The Ministry of Agriculture, Fisheries and Food

The Ministry of Agriculture, Fisheries and Food in Spain is responsible for agriculture, livestock, fisheries, food, and rural development. It has approximately 1,627 employees and in 2021 its annual budget was $9.7 billion (€8.9 billion).

The Ministry for Ecological Transition and the Demographic Challenge

About The Ministry for Ecological Transition and the Demographic Challenge

The Ministry for Ecological Transition and the Demographic Challenge in Spain manages the country’s response to climate change, pollution, biodiversity, in addition to protecting its natural heritage more broadly. In 2021, the ministry had an annual budget of $16.8 billion (€13.8 billion).

About DXC Technnology

DXC Technology helps global companies run their mission critical systems and operations while modernizing IT, optimizing data architectures, and ensuring security and scalability across public, private, and hybrid clouds. Global companies and public sector organizations trust DXC Technology to deploy services across the enterprise technology stack to drive new levels of performance, competitiveness, and customer experience.  

Published October 2021