Porosity prediction from X-ray computed tomography logs (RHOB and PEF) using Artificial Neural Networks (ANN)

This work presents a method for rock porosity prediction from the X-ray computed tomography (CT) logs obtained using a double energy approach, bulk density (RHOB) and photoelectric factor (PEF). The proposed method seeks to correlate the known porosity from the Routine Core Analysis (RCAL) with RHOB and PEF high-resolution logs, as the response of these two measurements depends on the volumetric quantity of different rock materials and of the volume of its porous space. Artificial Neural Networks (ANNs) are trained so they can predict porosity from CT logs at a high resolution (0.625 mm). The ANNs validation and regression plots show that porosity predictions are good. High-resolution porosity models linked to CT images could contribute to enhancing the petrophysics model as they allow a more refined identification of intervals of interest due to the detailed measurement.


Introduction
X-ray computed tomography (CT) applied to rock samples is a very useful tool due to its ability to inspect the internal structure of the rock in a non-intrusive way, this allows verifying the status of the drilling cores inside their aluminum barrel and to obtain a digital reconstruction of the initial state of the rocks that will be conserved in time (Withjack et al., 2003).
Currently, tomography images are normally obtained within the rock sample characterization workflow (Akin and Kovscek, 2003), and they are used to facilitate and improve operational processes such as the geological description or the extraction of plug-type rock samples (1'' or 1.5'' diameter) from the full diameter cores. Additionally, as this type of tomography is based on determining the attenuation that matter produces on the X-rays that pass through it, the phenomena involved can be used to estimate different properties of the rock (Kantzas et al., 1992).
The X-rays attenuation is related to two material properties, its density, and its effective atomic number, as this phenomenon occurs because of two different effects, the Compton effect related to bulk density, and the photoelectric effect related to the effective atomic number. As these two effects have a non-linear response to the X-rays energy level, scanning the rocks at two different energy levels gives enough information to determine both, bulk density and effective atomic number (it can be converted to a photoelectric factor PEF). The method and calculations used for this estimation are presented elsewhere (Siddiqui and Khamees, 2004;Ortiz-Meneses et al., 2015).
Many other authors have made efforts to integrate these measurements within the reservoir characterization and to get the most out of them (Calzado and Geleijns, 2010;Funk et al., 2011). It is important to consider that the measurements made with CT generate high-resolution logs (0.002 ft approx.), with a much more detailed scale than the well logs (0.5 ft approx.); On the other hand, tools to obtain well logs perform an average reading of everything that is found near the wellbore, while in the tomography logs, as their interpretation is done by choosing a region of interest (ROI) over the rock, the measurements are effectively made on this ROI (avoiding fractures, cracks, unwanted materials, etc.) and therefore, they may differ from those obtained in the well.
Several approaches have been proposed for porosity determination using tomography, Akin et al. (2000) estimated porosity by means of a dual scan (not dualenergy) in the same location using different known fluid saturation of the porous medium. Akin et al. (1996) proposed a method that uses a dual scan at two different energy levels. These and other methods that use dual or simple scanning are described by Akin and Kovscek (2003). However, these approaches do not apply to fulldiameter drilling cores as those considered in this paper. Similarly, Larmagnat et al. (2019) proposed an improved method to generate 3D porosity maps using CT images of core samples at different states (dry and saturated state) for heterogeneous sedimentary rocks.
On the other hand, ANNs have been used for rock property predictions based on well logs. Konaté et al. (2015) designed ANNs to predict porosity in continental crystalline rocks from four logs (density, neutron porosity, sonic and resistivity), they found that ANNs provide better performances with sets of three geophysical well logs (density, sonic and resistivity) than a regression technique. Singh et al. (2016) created back-propagation artificial neural network (BP-ANN) to estimate the reliable porosity values from the well log data taken from Kansas gas field, they used as input sonic, density and resistivity log data; they found that porosity generated by their ANNs has a high degree of the correlation with the one generated from combined density and neutron data. Sun et al. (2001) used ANN inversion to populate the porosity of a reservoir model for a producing zone in Bermejo Field. Al-Bulushi et al. (2007) developed a methodology based on ANNs to predict water saturation using wire-line logs and Dean-Stark core data. Finally, White et al. (1995) developed successfully several ANNs for zone identification in a heterogeneous formation from geophysical logs (Gamma Ray, Deep Induction and Bulk Density), and core description and analysis.
This work presents a new approach based on Artificial Neural Networks (ANNs) for porosity prediction from RHOB and PEF data estimated by CT. ANNs are trained using porosity data from laboratory measurements.
As CT logs have a high resolution, up to 0.625 mm, a high-resolution porosity model could be made, so more detailed information about porosity would be obtained and the porosity estimation would be improved as no fracture or void space is taking account on CT analysis.

Theoretical framework
Bulk density (RHOB) and photoelectric factor (PEF) estimations in the rock are made by using a dualenergy approach, where the rock sample is scanned at two energy levels, one high (greater than 100 kV), and other low (less than or equal to 100 kV), in addition, materials of known properties are scanned with it, this allows identifying in each slice (image), the relationship between the X-ray attenuation (CT numbers) in both images and the known RHOB and PEF. Subsequently, the results are calibrated using rock samples with known properties and necessary shifts on the calculated properties are made, this ensures the accuracy of the estimated values. A more detailed description of the methodology is presented elsewhere (Ortiz-Meneses et al., 2015).
Importantly, this estimation is made by taking CT numbers from the rock images on specific areas called Regions of Interest (ROI), thus preventing measurements of sections that could deflect the calculation, such as fractures or void spaces. According to this, it can be expected that the logs taken in the well do not match exactly those interpreted from CT images. Correspondingly, it can be inferred that these CT logs will present not only a high resolution but a high accuracy. The method used in this work has been shown to estimate the RHOB of the rock with a relative error of less than 3%. On the other hand, linking images of the inside of the rock to logs allows the interpreter to check where the measures were taken and improve the calculation in case that it was necessary.
As mentioned, porosity is predicted from RHOB and PEF. Note that even when PEF is not directly affected by porosity, it is a function of lithology which is related to grain density, thus it is involved in the relation between porosity and bulk density (RHOB). Including PEF in the prediction allows defining changes in the relation between RHOB and porosity when lithology changes.

Proposed methodology for porosity prediction
In this study, data from drilling cores from a Colombian oilfield is used, over 100 ft of rock were scanned at 0.625 mm interslice resolution (vertical resolution of 0.002 ft) using a CT medical scanner, RHOB and PEF data were estimated for every image using the methodology mentioned above to obtain high resolution-logs. 62 samples were taken from different depths to RCAL, Boyle helium porosity, air permeability, and Dean-Stark saturation data were obtained for all of them.
A Matlab script is developed to identifying RHOB and PEF values for every sample from the highresolution logs. Subsequently, another script is made for generating and training feedforward ANNs using the known data and the Matlab training tools. This script allows the user to select topology for creating and training new ANNs, in each case, it shows regression plots of predicted data versus real data so the user can evaluate performance of the ANN. The created nets use hyperbolic tangent sigmoid transfer functions ant they are trained using Levenberg-Marquardt backpropagation, detailed information about parameters used in training is shown in Table 1. Different scenarios and ANN topologies are studied to evaluate the quality of the result. In the first scenario, a single-layer ten neurons ANN (ANN 1) is trained using all the available data. Figure 1 shows the regression plots for predicted porosity vs real porosity when using training, validation, and test data and all data.
As it can be seen results obtained are good as slopes and R squared coefficients are close enough to 1 in all cases and intercepts tend to 0, but it is important to note that, as training data is selected randomly, results may change on every application, a quick inspection is made running the training algorithm a couple of times more, results are shown in Table 2, note that quality of the results obtained using this topology are acceptable, as R squared values are greater than 0.5, but no close enough to 1 and they change strongly over different runs.  Over 20 runs are made increasing the neurons amount (5 neurons steps) while searching the best topology for this problem, one-layer ANNs with a higher number of neurons (up to 50) are tried, it is found that even when regression values are good in general, overfit problems appear as some predicted porosities are less than zero.
Finally, it is found that an ANN topology of 3 hidden layers with 10 neurons each layer is appropriated for this case, the regression values obtained in three different runs for this topology are shown in Table 3, while regression plots for the last run are shown in Figure 2.  The obtained regression plots show that good correlation exists between porosity and CT logs so, it could be possible to obtain a predicted porosity log from the use of the appropriated ANN, as it can be seen in Figure 2, where predicted values on validation and test plots are close enough from the real ones.
The proposed algorithm is improved so the user can run the ANN training several times (changing topology if necessary) while checking quality in every case. When a good performance ANN is found, the user can save its configuration and apply it to predict porosity over the whole well. Later, the algorithm generates a report where shows predicted porosity logs linked to CT logs (RHOB and PEF) and CT images, as shown in Figure 3, where it can be seen a good match between predicted and real data and consistent results with CT images. Figure 3. Predicted porosity log compared with real porosity data linked to a CT image of a 3 feet long core section.

Artificial neural network application
Porosity prediction is made for every core section of the well, using three hidden layers and ten neurons ANN that showed a good performance on regression plots (the third one showed in Table 2). Porosity plots are obtained for every core section and in all of them predicted values are close to the real ones and show a good concordance with CT images. Figure 3 shows prediction on 3 feet core section composed mainly of Sublitharenites, note that predicted values (green line) match properly the known values (red circles).
In CT images lighter colors correspond to high x-ray attenuation materials, this means high RHOB, high PEF, or a combination of both. In this figure, high PEF occurs due to the presence of siderite (according to the core description).   (Figure 4) shows Sublitharenites with limestone cement, upper right example shows Sublitharenites, lower left example shows fine-grained sandstone with siderite laminations that increase PEF and lower right example shows mudstones and very fine-grained sandstone, in this case, white sections on CT image correspond to siderite. Note that known porosity values decrease when RHOB or PEF increases (when X-ray attenuation increases), predicted values show the same behavior.

Discussion
As shown in Figure 3 and Figure 4, predicted porosity logs have a good match with laboratory measurement porosities. On the other hand, higher values of RHOB or PEF generate lower porosity, which is expected according to the theoretical knowledge where higher bulk density values mean less porous space when grain density is constant. Note that porosity is affected by PEF even when RHOB keeps constant, this is theoretical consistent as PEF changes indicate lithology changes and therefore, variations on grain density. If grain density changes, porosity has to change in order to keep RHOB constant according to Equation 1.
Where, ρ g is grain density, ρ f is fluid density and φ is porosity.
The good agreement between the predicted and the measured data is a sign that the response of these two logs provides enough information to find an acceptable prediction. However, it is important to note that, if one wishes to include the effect of fluid saturation on the relationship between the CT logs and porosity, neutron or resistive logs must be included in the ANN training and prediction, which is a challenge considering the difference of scales.

Conclusions
The values of the regression plots obtained from ANNs training show that there is a relationship between CT logs and porosity, good enough to use these ANNs to obtain high-resolution porosity logs for the entire well, linked to the CT images of the core.
A Matlab algorithm was implemented which facilitates the generation, training, and use of these ANNs, allowing the user to test different topologies and evaluate the quality obtained. The algorithm also generates automatic reports where predicted porosity logs are linked to the CT images of every core section.
It is found that, in this case, a topology of three hidden layers with ten neurons in each one gives good results.
In the studied well it was found that porosity decrees when RHOB or PEF values increase. When RHOB is constant, changes on porosity could be related to changes on grain density and therefore changes on lithology, affecting PEF values, this behavior was observed for this well.
When comparing predicted porosities with the measured ones, it is found that the performance of the ANN generated was mainly good. Highresolution porosity models were obtained for the cores which can contribute to improve their petrophysical characterization and to identify new intervals of interest.