Ghulam Mustafa

Ghulam Mustafa is a PhD candidate in Computer Science and Engineering at the University of Bologna. His research focuses on machine learning for gamma-ray astrophysics, particularly COSI background prediction, transient detection, and localization.


Sessions

11-02
10:27
9min
ARCADIA: AI-based Real-time Analysis for Autonomous Space Systems
Ghulam Mustafa, Nicolò Parmiggiani

The New Space Economy, enabled by the increasing availability of commercial launch vehicles and spacecraft, has renewed interest in lunar exploration. Within the Italian PRORIS program and the HARLOCK project, the Rare-earth & Heavy Elements Analyzer (RHEA) is being developed. RHEA is a payload consisting of a suite of instruments designed for integration on small rovers, enabling rare earth element (REE) and rare-metal scouting and prospecting through a highly coordinated and synergistic approach based on a progressive and multiscale observation strategy. RHEA combines gamma-ray spectroscopy, hyperspectral imaging, ultraviolet fluorescence screening, and X-ray fluorescence analysis to identify and characterize REE-bearing deposits and associated elemental and mineralogical signatures across different spatial scales. Its operation in the lunar environment is constrained by limited onboard power and communication bandwidth with Earth, making artificial intelligence (AI) a key enabling technology for autonomous scientific operations and onboard data processing.

We present the AI-based Real-time Computational Analysis platform for Decision Inference in Autonomous space systems (ARCADIA), which implements the Instrument Control Unit (ICU) and onboard Data Processing Unit (DPU) for the RHEA rover. The ICU controls and monitors the scientific payload, while the DPU performs AI-enhanced onboard data analysis, including spectral identification of REEs, real-time multi-instrument data fusion, and data reduction. These capabilities support the generation of scientific products, autonomous decision-making, and efficient use of communication bandwidth and onboard storage. Real-time onboard processing of scientific data enables ARCADIA to enhance the effectiveness of the scouting process by rapidly guiding the rover toward the most promising sites for further investigation, thereby accelerating target selection and exploration even during short-duration missions.

The ARCADIA software architecture includes interfaces with the rover and scientific payloads. A market survey of low-power Commercial Off-The-Shelf (COTS) computing platforms was conducted to identify solutions meeting the project requirements for power consumption, computational capability, and environmental constraints. AI algorithms for onboard data analysis were evaluated on low-power edge-computing platforms, including the NVIDIA Jetson Nano, and on RISC-V processors representative of flight-proven hardware. Candidate platforms target a power consumption below 5 W while supporting AI models optimized through pruning and quantization, with the goal of enabling real-time onboard processing under lunar resource constraints.

The technologies and methodologies developed within ARCADIA are designed to be transferable to other autonomous space systems and adaptable to a broader range of future space missions.

AI as tool for scientific discovery
Seminar Room 2
11-02
15:36
12min
Explainable XRF Element Detection with Embedding-Space KNN and Physics-Based Masks for the HARLOCK Lunar Rover
Alberto Luise, Ghulam Mustafa

In astrophysics, Deep neural networks have achieved state-of-the-art performance in a variety of spectral analysis tasks. However, these models are often considered "black boxes", providing limited insight into predictions and requiring post-hoc tools for explanations. This lack of transparency can limit their adoption in scientific contexts, as in these environments interpretability is essential. This is one of the challenges in the development of RHEA, the Rare-earth \& Heavy Elements Analyzer of the HARLOCK project within the PRORIS program. It combines gamma-ray spectroscopy, multispectral imaging, ultraviolet fluorescence screening and X-ray fluorescence analysis to identify Rare-Earth Elements (REE) deposits and associated elemental and mineralogical signatures across different spatial scales.

In this work, we propose a model-agnostic framework that converts any Convolutional spectral classifier into an explainable predictor without hindering its performance on multiple metrics, demonstrating it on a complete model working with attention masks for additional insight and training stability. Our approach exploits the Neural Network's latent representation and preservation of spatial features: after training, the final regression layer of the backbone model is removed and replaced by a K-Nearest Neighbors (KNN) regressor operating directly on the learned embedding space; as a result, every prediction is accompanied by an explanation in the form of the most similar spectra observed during training. This works particularly well thanks to a custom loss function designed to optimize the quality of the learned embedding space, without hindering performances.

Furthermore, in our model, for each predicted element an associated attention mask is learned at training time starting from a physics-based initialization. This way, the framework provides, alongside instance-level explanations, easily readable heatmaps in the form of a mask-by-weights product, allowing users to trace model outputs back to representative examples in the training data and the relevant parts of the input used. Experimental results show that, in a regression task estimating the composition of soil samples, the average R2 score over the predicted elements stays around 0.9 for both the original approach and the explainable Deep kNN model (depending on the complexity of the task).

Our proposal offers a practical path toward trustworthy AI for spectroscopy, combining the representational power of deep learning with the transparency of example-based reasoning.

AI as tool for scientific discovery
Seminar Room 2
11-02
15:48
12min
Machine-Learning-Based Event Classification of Terrestrial Gamma-ray Flashes with a Segmented Scintillator Detector
Ghulam Mustafa, Antonio

Terrestrial Gamma-ray Flashes (TGFs) are sub-millisecond bursts of atmospheric gamma rays associated with thunderstorms and are of particular interest for space-based gamma-ray observations. Their detection from orbit requires the identification of brief gamma-ray signals in the presence of background, while operating under the limited computational and power resources typically available on CubeSat-class spacecraft. Within this context, the Gamma-Sky project is investigating low-power Edge-AI approaches for the real-time processing of high-energy radiation, using atmospheric X- and gamma-ray detector data. This work presents a machine-learning-based event-classification methodology for a CubeSat-class mission, exploiting the spatial and energy information provided by a segmented scintillator detector architecture. The proposed detector consists of multiple scintillator elements distributed throughout the detector volume rather than a single monolithic crystal. This configuration enables the identification of characteristic event patterns related to deposited energy, multiplicity of interactions, and spatial correlations between detector elements. The detector response is used to extract a compact set of event-level features suitable for machine-learning analysis. A dedicated algorithm is then developed to distinguish gamma-ray interactions from charged-particle-induced background, reducing the charged-particle contamination of a TGF event. The simulation results show that the spatial and energy-deposition information provided by the segmented detector offers effective discrimination between gamma-ray interactions and charged-particle-induced events. The processing chain is designed for resource-constrained onboard operation, with particular attention to reducing the computational and memory requirements of the trained models. Quantization and pruning are applied to obtain a lightweight implementation while preserving the event-classification capability. The resulting algorithm is suitable for deployment and experimental validation on embedded Edge-AI platforms. Preliminary results indicate the potential of combining detector segmentation, machine-learning-based event classification for background rejection, and efficient onboard processing in future compact high-energy space instruments dedicated to TGF observations.

AI as tool for scientific discovery
Seminar Room 2
11-03
10:12
12min
Machine Learning Models for Predicting the COSI Background for Gamma-Ray Burst Detection
Ghulam Mustafa

The Compton Spectrometer and Imager (COSI) is a NASA Small Explorer mission designed to study the MeV gamma-ray sky, including gamma-ray bursts (GRBs), compact objects, nuclear emission lines, and other high-energy sources. Reliable background prediction is important for transient searches because the background changes with spacecraft position, pointing direction, and time. The aim of this paper is to develop a probabilistic machine-learning framework for COSI background prediction to support GRB detection and localization. The framework consists of four main stages. The Angular Resolution Measure (ARM) method is used to filter the event data and generate light curves for different sky positions following the HEALPix grid. These background light curves are then used to train a probabilistic regression model and derive significance thresholds from its predictive distribution. The trained model is applied to the same sky positions within the COSI field of view to estimate the expected background. The observed light curves are then compared with the predicted background and significance thresholds to search for significant excesses associated with GRBs and support their detection and localization. In this work, we focus on developing and evaluating the background regression models using simulated DC4 background events and spacecraft information. For the regression analysis presented here, we use an ARM-selected background light curve with one-second bins. Spacecraft livetime information is used to select valid observing periods and remove bins close to South Atlantic Anomaly boundaries. The model inputs include the time elapsed since the start of the selected DC4 modeling interval, spacecraft altitude, the Earth-zenith direction, and spacecraft pointing orientation. The spacecraft pointing directions are originally given in Galactic coordinates and are represented in the models using Cartesian components. From the DC4 dataset, two consecutive orbits are reserved as a held-out temporal test block, while the remaining data are randomly divided into training and test sets. Only background events are used for model training and evaluation. We compare Poisson regression with a four-component Gaussian Mixture Regression (GMR) model, with the GMR providing a more flexible predictive distribution. The current results show that both models follow the large-scale evolution of the ARM-selected background. As future work, we plan to evaluate the trained background prediction models using simulated GRBs to measure their performance for transient detection and localization.

AI as tool for scientific discovery
Seminar Room 2
11-04
10:12
12min
Quantum Annealing for Gamma-Ray Source Detection and Localization with AGILE Data
Ghulam Mustafa, Alessandro Rizzo

The detection and localization of gamma-ray sources is a complex optimization problem, requiring the estimation of parameters such as the source flux, background, position, and detection significance. AGILE is an Italian Space Agency mission whose Gamma-Ray Imaging Detector (GRID) surveyed the sky in the 30 MeV-50 GeV band and produced photon count maps. Detecting gamma-ray sources in this data can be challenging because of low photon counts, which require specific methods to separate the source from the diffuse background. For this reason, the classical approach to detect and localize gamma-ray sources is the Maximum Likelihood Estimation (MLE). This fitting problem can be seen as an optimization over the model parameters, making it a candidate for quantum annealing, a computational paradigm that solves optimization problems by encoding them into the ground state of an Ising Hamiltonian. This technique does so through a slow, controlled process that evolves into the minimum-energy configuration, which then encodes the solution to the optimization problem, representing a promising approach in the current Noisy Intermediate-Scale Quantum era. In this work, we reformulate the standard likelihood analysis of AGILE-GRID data as a Quadratic Unconstrained Binary Optimization (QUBO) problem, making the cost function quadratic and expressing the model parameters in binary form, as required by a quantum annealer. This approach could speed up the analysis of complex data, where the classical MLE fit becomes slow or may fail to converge.
We solve this task with simulated quantum annealing and benchmark it against the classical pipeline implemented in AGILEpy, the official analysis library for the AGILE mission, on 200 simulated observations at extragalactic latitude. Both the classical and quantum approaches recover the source flux accurately, with a systematic error of +2.8% for the former and -0.3% for the latter. For the isotropic background, the mean raw residuals are -0.87 (QUBO) and -0.58 (classical). We also found that the QUBO identifies the correct position among the 81 candidate positions on a grid with of 0.5° resolution in 90% of the maps. These results show that the quantum approach achieves accuracy close to that of the classical pipeline, a promising result for applying quantum annealing to gamma-ray source detection and localization. As a next step, we plan to test the method on real quantum annealing hardware.

AI as tool for scientific discovery
Seminar Room 2