{'fraction_non_alphanumeric': 0.022763706316126963, 'fraction_numerical': 0.014668162872715614, 'mean_word_length': 5.201292246520874, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Rapid determination of inner quality parameters of intact mango fruits using portable near infrared spectroscopy

Quality inspections in agricultural product industries is a critical step to ensure high standard of the products. The main purpose of this present study is to apply the near infrared spectroscopy as a rapid and simultaneous method in determining inner quality parameters of intact mango fruits as vitamin C and total acidity. Absorbance spectra data of mango samples were acquired using a portable sensing device NIRS in wavelength region of 1000-2500 nm and resolution windows 0.02 nm. On the other hand, actual vitamin C and total acidity contents of mango fruit were measured by means of standard laboratory procedures. Prediction model were built using raw and enhanced spectra data with partial least square regression approach. The results showed that both quality parameters can be determined simultaneously with maximum correlation of 0.92 for vitamin C and 0.94 for total acidity. It may conclude that near infrared spectroscopy can be employed for a rapid and environmental friendly approach in mango quality inspections.


Introduction
Mango fruit (Mangifera indica) is one of the most important and popular agricultural products in the tropics. This fruit belong to stone fruit (drupa) which has 3 layers of fruit walls. The three layers of fruit wall are thin exocarp (peel), fleshy or stringy mesocarp and endocarp which is thick and hard as stone. Mango usually grows in hotter environments and widely cultivated around the world due to their overall nutritional values [1], [2]. India, China, Thailand, Indonesia and Pakistan are the largest mango producing countries in the World and exported widely to Europe and Americas [3], [4].
Generally, consumers preferred mango and other agricultural products in good condition both physical and chemical properties. Therefore, quality inspection plays an important role in every phase of agriculture processes industries. Sorting and grading phase are two major steps in surrounding environment of horticulture and agriculture industries. Mango fruits can be sorted based on physical appearances like shape, weight, and color [5]. On the other hand, grading normally related to inner quality parameters of mango from which classified as quality classes. [6], [7] Total acidity and vitamin C are two most important quality attributes of mango and also for other horticultural products. Both of them represent overall nutritional value of mango fruit and cannot be justified based on their physical appearance [8], [9]. To determine total acidity (TA) and vitamin C of 2 mango and other fruits, normally we bring them to the laboratory for chemical analysis. Several known methods were widely employed. Yet, most of those methods are based on wet chemical analysis which are time consuming, laborious, and may cause environmental pollutions since these methods involved chemical materials in their wet analysis [10], [11].
To date, the development of rapid and non-destructive method in determining quality attributes of agricultural products is gaining more attentions. Many studies have been reported to be implemented for agricultural products quality inspection like the application of computer vision, ultrasound and infrared spectroscopy for sorting and grading processes. The advantage of this method are fast, effective, simple preparation, and environmental friendly [12], [13]. Last but not least, these methods have the ability to determine several quality attributes in the same time simultaneously. Near infrared spectroscopy (NIRS) is the method which is more attractive among others and have been reported to be employed in many field including in agriculture and horticulture, also in environmental studies [14]- [16].
Numerous research and publications have been carried out regarding with the application of NIRS method in agriculture such as fruit quality control assessment [17], [18], crops and agricultural products inspection [19]- [21], soil properties determination [14], [22], [23], and also for animal product evaluation [24], [25]. Based on the ability of NIRS in determining several quality parameters, further investigation was performed to develop calibration models used to predict and simultaneously determine the total acidity and vitamin C of intact mango fruits respectively.

Sample Preparation
A total of 50 mango fruits were used as samples with varied maturity stages. Mango fruits were purchased from local markets with different level of maturity and stored at 25 o C and 84% of relative humidity for around two days to equilibrate their condition. Then, on the next day, mango samples were bring to the lab for spectra data acquisitions, and for total acidity and vitamin C measurement [9].

Spectra Data Acquisition
Absorbance spectra data for mango fruits were acquired in wavelength range from 1000 to 2500 nm or in wavenumbers range 4000-10 000 cm -1 , using a portable sensing device (PSD) NIRS instrument i16 [7], [26]. Spectra data were measured with 0.2 nm intervals and co-added of 4x optical gain. For robust prediction performance, near infrared spectra data were enhanced using spectra correction methods namely mean centering (MC) and baseline shift correction (BSC).

Prediction Models
The core section of near infrared spectroscopy application is to develop and establish prediction models that are used to determine inner quality parameters of studied object where in this case are total acidity and vitamin C of intact mango fruits. Prediction models were developed using raw original uncorrected and corrected spectra data by means of principal component regression (PCR) followed with leverage cross validation approach. The models were evaluated using these following statistical parameters namely coefficient of determination (R 2 ), correlation coefficient and ratio prediction to deviation (RPD) index [9], [27].

Mango Fruit Spectra Features
As we knew that mango is a niological object that containd more water with almost 80% inside. Thus, the highest spectra peak absorbance are found in 1460 nm and 1920 nm which are correspons to O-H bands. This also in agrreement with several findings moted that water and moisture content bands can be found on the near infrare region at around 1450 nm and 1920 nm respectively. More detailed spectra features of intact mango fruit samples can is shown in Figure 1. Besides O-H bands, the spectra features were also mentioned other chemical stuctures that are vibrated along the near infrared wavelength region.
The absorbance spetrum bands for C-H-O related to fibre contents were overtyoned in wavelength range from 1283 -1357 nm, whereas for acidity can be found in 1159 -1204 nm as first overtone, and in the region 1674 -1805 nm as second overtone. These finds are also noted by previous findings from which C-H-O structures related to acidity content of fruits are found in those wavelength region [4], [28], [29]. Moreover, other C-H-O structures which is related to sugar contents, can be found in wavelenth range from 2100 to 2300 nm. These bands are associated with total soluble solids, carbohuydrates and also other individual sugar of intact mango fruit. From this point of view, the spectra feature captured in near infrared region can be used to determine those inner qualityu attributes by means of spectral data in tandem with particular multivariate approaches like principal component regression, partial least square or other linear and non-linear regression approaches.
The actual measurement data of inner quality attributes in mango samples were determined by standard laboratory procedures where in this case, we employ a titration method both for total acidity and vitamin C measurements. The descriptive statistics for actual total acidity and vitamin C data for all 50 mango fruit samples is presented in Table 1. Prediction models for N and Mg determination were established by means of partial least square regression (PLSR) approach. In general, this method is more widely used because with this method data in the spectrum are reduced to prevent overfitting problems without losing one or some very useful information. Calibration carried out with PLSR, takes into account reference data in the formation of the model. This approach is a multivariate calibration method for estimating the content of a material using a linear combination to estimate the independent variables from the original variables [30], [31]. In the PLSR method, variables that show a very high correlation with dependent variables will be given a large weight because these variables will be more effective in estimating. The NIRS spectrum calibration stage using the PLSR method also uses some data processing. Each data processing carried out has their respective functions.

Mango Quality Attributes Prediction
The main part of near infrared spectroscopy application is to establish prediction models used to determine inner quality parameters of studied object by projecting onto regression approaches like principal component regression (PCR), partial least square regression (PLSR), and so forth. In present works, spectral data of intact mango fruits were used as independent varaibles while actual inner quality attributes were used as dependant variables in regression. Firtsly, prediction models for TA and vitamin C were developed using raw uncorrected spectra data by bmeans of PCR regression approach as presented in Figure 2 and Figure 3.   The prediction performance results for total acidity determination using raw spectra data achieved the correlation coefficient 0.93, while for vitamin C determination, the achieved correlation coefficient is 0.89 respectively. The prediction accuracy and robustness were improved when the models are constructed by the corrected spectra data using multiplicative scatter correction (MSC). The correlation coefficient for TA determination improved to 0.96 while for vitamin C increased to 0.89 respectively. Detailed prediction performance for both TA and vitamin C using raw and MSC corrected spectral data are shown in Table 2 and Table 3.  The determination of total acidity and vitamin C on intact mango fruits achieved the best prediction performance when the models are developed using enhanced spectral data like MSC in this case. There are several methods that can be used to enhance and correct spectra data. Those methods have different characteristics in term of spectra variations and algorithms. The most common spectra corrections are multiplicative scatter corrections and standard normal variate. Scatter plot of prediction performance in determining TA on intact mango fruits is shown in Figure 4. Like total acidity, another quality parameter of intact mango is vitamin C content that can also be predicted very well by means of corrected spectra data. The MSC spectra generated prediction performance with correlation coefficient increase to 0.89 and ratio prediction to deviation (RPD) index also improved to 2.68. The RPD index related to the prediction model robustness for further determination of studied quality attributes. The good models should have little different in calibration and validation or we called it robust prediction model. Scatter plot describing prediction performance of vitamin C prediction on intact mango fruits using MSC spectra data is presented in Figure 5.
. Figure 5. Prediction performance of NIRS in determining vitamin C using MSC spectra data Furthermore, prediction models can also be developed using other regression approaches like support vector and artificial neural networks regression based. From validation perspective, it is important to perform validation during remodeling to avoid overfitting and over-optimistic performance. In spite of that, near infrared reflectance spectroscopy can be applied in tandem with proper data analysis for rapid and environmental friendly approach for mango quality inspections.

Conclusion
The application of near infrared reflectance spectroscopy for rapid and simultaneous inspection of inner quality attributes on intact mango is investigated. Prediction models were constructed by means of regression approach for raw and enhanced spectra data respectively. Based on obtained results, it may conclude that robust and accurate prediction models were achieved when the models are developed using enhanced and corrected spectral data.