A computer implemented method of performing characterization of one or more materials, the method comprising: scanning the one or more materials by means of a sensory system including an X-ray sensor configured to perform multi-energy imaging for obtaining at least a lower-energy X-ray image and a higher-energy X-ray image; performing segmentation of images obtained by means of the sensory system in order to separate one or more distinct objects in the images, wherein data indicative of an area of the segmented objects is determined; determining, for each of the segmented objects, data indicative of an area density and data indicative of an atom number by analysis of the lower-energy X-ray image and the higher-energy X-ray image, the data indicative of the area density and atom number being determined by means of a model which is calibrated by performing multi-energy X-ray imaging with different materials with known area densities and atom numbers; and characterized in that the method includes: calculating, for each of the segmented objects, data indicative of a mass based on the data indicative of the area density and the data indicative of the area of each of the segmented objects; and providing, for each of the segmented objects, at least the data indicative of the atom number as input to a trained neural network, wherein the trained neural network is configured to label each segmented object, wherein the data indicative of the mass is coupled to each of the labeled segmented objects, and in that the calculated mass is provided as input to the trained neural network. scanning the one or more materials by means of a sensory system including an X-ray sensor configured to perform multi-energy imaging for obtaining at least a lower-energy X-ray image and a higher-energy X-ray image; performing segmentation of images obtained by means of the sensory system in order to separate one or more distinct objects in the images, wherein data indicative of an area of the segmented objects is determined; determining, for each of the segmented objects, data indicative of an area density and data indicative of an atom number by analysis of the lower-energy X-ray image and the higher-energy X-ray image, the data indicative of the area density and atom number being determined by means of a model which is calibrated by performing multi-energy X-ray imaging with different materials with known area densities and atom numbers; and characterized in that the method includes: calculating, for each of the segmented objects, data indicative of a mass based on the data indicative of the area density and the data indicative of the area of each of the segmented objects; and providing, for each of the segmented objects, at least the data indicative of the atom number as input to a trained neural network, wherein the trained neural network is configured to label each segmented object, wherein the data indicative of the mass is coupled to each of the labeled segmented objects, and in that the calculated mass is provided as input to the trained neural network. calculating, for each of the segmented objects, data indicative of a mass based on the data indicative of the area density and the data indicative of the area of each of the segmented objects; and providing, for each of the segmented objects, at least the data indicative of the atom number as input to a trained neural network, wherein the trained neural network is configured to label each segmented object, wherein the data indicative of the mass is coupled to each of the labeled segmented objects, and in that the calculated mass is provided as input to the trained neural network.