## 4 Machine Learning Analysis Based on Actual Measurement Data
### Creation of Training Data and Building Machine Learning Model  
Figure 8 shows one of the neutron transmission images during the LBE solidification process as an example of the data measured. The figure shows a neutron wavelength-resolved radiogram with a neutron wavelength of 0.530\(\sim\)0.537 nm near the \(\beta\)(101) Bragg-edge of LBE. The relatively uniform zone at the bottom of the figure is considered the zone where the sample did not melt during the first 60 min of heating. Upward from there, the zone where black and white vertical shades can be seen is considered the zone that was solidified through the solidification process. The slightly darker gray zone in the upper part (surrounded by a red frame) is estimated to be the zone where the solid-liquid interface moved during the 30 min integration measurement, and the uppermost uniform zone is the LBE melt. Although the approximate location of the solidification interface can be estimated  
Figure 7: Difference in analytical performance (root mean square error (RMSE)) for the test data with random errors (\(\sigma\) = 0\(-\)10%). The training data with random errors (\(\sigma\) = 0\(-\)5%) were used to build the machine learning (ML) model using KNN.  
from the obtained images, it is necessary to evaluate the solid-liquid phase fraction to investigate its location in detail. The target of this study was to determine the rate at which this red zone moves from the bottom to the top during the solidification experiment.  
The training spectral dataset used for the ML analysis was created from neutron transmission spectra from TOF imaging experiments. For obtaining the liquid-phase spectrum shown in Figure 9, we averaged the entire zone where the liquid-phase was judged to be 100% in the first 60-min measurement, identified by the temperature information with the thermocouples inserted in the sample. For the spectrum of the solid phase, the data after the entire sample was solidified were picked out in a 45 horizontal pixel \(\times\) 2 vertical pixel section, avoiding the thermocouple insertion area, and these pixels were integrated and averaged together. Then, eventually, 50 types of solid-phase spectra were sampled for every two vertical pixels. Figure 10 shows some of the spectra obtained. The solid-phase spectra obtained from the different points show differences in texture. The effect of the sample container was removed as a background during these procedures.  
Figure 8: Neutron transmission imaging (80 mm \(\times\) 80 mm) of the LBE sample during solidification (neutron wavelength: 0.530–0.537 nm; measurement time: 30 min). The red frame in the figure was considered the solid–liquid interface zone.  
Figure 9: Neutron transmission spectrum of LBE melt obtained by integrating the 100% liquid-phase zone from the TOF imaging experiment.  
Using the spectra for the 100% liquid phase (1 kind) and 100% solid phase (50 kinds), prepared as described above, we created a training dataset of LBE neutron transmission spectra for solid-phase fractions from 0 to 100% in 1% increments following the procedure described in Section 3.1. Since we prepared 50 types of solid-phase spectra, the total number of neutron transmission spectra in the created training dataset was 5001. These spectra were then dimensionally reduced to 3 by PCA, and 5001 of these spectra were trained to build an ML model for the KNN.