Infrared spectroscopic analysis detection method and detection device for petroleum products
Through infrared spectroscopy detection methods and BP neural network, pre-processing and model selection are carried out according to the use of petroleum, which solves the problem of inaccurate aging assessment in the existing technology, and achieves more accurate aging assessment results to meet the accurate needs of the petroleum industry. .
Patent Information
- Application Number
- CN202411640750.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-18
- Publication Date
- 2024-12-13
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing petroleum aging assessment methods cannot be distinguished based on the different uses of oil, resulting in inaccurate assessment results and difficult to meet the precise demands of the oil industry for oil quality monitoring and aging assessment.
Infrared spectroscopy detection method is used to select the corresponding pretreatment scheme and aging evaluation model according to the purpose of petroleum, and aging evaluation is performed through differential graphs and BP neural networks to improve the accuracy of the evaluation results.
It realizes targeted evaluation based on oil use, improves the accuracy and reliability of aging assessment, can more accurately reflect the aging characteristics of oils for different uses, optimizes the training process of the aging assessment model, and improves the prediction performance and generalization capabilities. .
Smart Images

Figure CN119125060A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of petroleum product detection, and in particular to an infrared spectrum analysis detection method and a detection device for petroleum products. Background Art
[0002] During the storage and use of oil, due to long-term exposure to air, high temperature or light, oil will undergo a series of complex chemical reactions, causing changes in the chemical composition of oil, which in turn affects its physical and chemical properties, not only reducing the performance of oil, but also causing damage to equipment and even causing safety accidents. Therefore, accurately assessing the degree of oil aging is of great significance for ensuring oil quality, extending service life, preventing equipment failures and ensuring environmental safety.
[0003] Although the importance of oil aging assessment has been widely recognized, existing assessment methods still have obvious shortcomings, such as failing to fully consider the special requirements of different uses of oil for assessment methods. In practical applications, oil is widely used as a fuel and chemical raw material, and different uses often mean that oil has significant differences in chemical composition, physical properties and aging mechanisms. However, existing assessment methods fail to make detailed distinctions based on these differences, but simply use a unified large model for aging assessment. This approach not only ignores the diversity of oil uses, but also fails to fully capture the unique characteristics of oil with different uses during the aging process, resulting in inaccurate assessment results, which makes it difficult to meet the oil industry's precise needs for oil quality monitoring and aging assessment.
[0004] Therefore, the existing petroleum aging assessment methods do not differentiate the assessment methods according to the use of petroleum, and use a unified large model for aging assessment, which leads to problems such as inaccurate assessment results and is difficult to meet the urgent needs of the petroleum industry for oil quality monitoring and aging assessment. Summary of the invention
[0005] The present invention provides an infrared spectrum analysis and detection method and a detection device for petroleum products, so as to differentiate evaluation methods according to the use of petroleum, adopt a targeted large model to perform aging evaluation, and improve the accuracy of evaluation results.
[0006] An infrared spectrum analysis and detection method for petroleum oil products specifically comprises the following steps: Step S1, obtaining the use of the petroleum to be tested; the use includes: fuel and chemical raw material; Step S2, obtaining an infrared spectrum of the oil to be tested and an infrared spectrum of the oil to be tested before aging; Step S3, determining a preprocessing scheme of the infrared spectrum according to the purpose; Step S4, calculating a difference image according to the two pre-processed infrared spectra obtained in step S3; Step S5, selecting a model for petroleum aging assessment according to the use, specifically: if the use is fuel, selecting a first aging assessment model, if the use is chemical raw materials, selecting a second aging assessment model; Step S6, inputting the difference map into the trained aging assessment model, and outputting the aging assessment result of the tested petroleum.
[0007] Furthermore, in step S3, the preprocessing scheme of the infrared spectrum is determined according to the purpose, specifically: If the use is fuel, the preprocessing measures are: denoising, baseline correction and spectral smoothing; If the stated purpose is chemical raw materials, the preprocessing measures adopted are: denoising, resolution enhancement and data standardization.
[0008] Furthermore, in step S4, a difference graph is calculated based on the two pre-processed infrared spectra, specifically: Step S41, obtaining an infrared spectrum of the pretreated petroleum to be tested and an infrared spectrum of the pretreated petroleum before aging; Step S42, aligning the two infrared spectra obtained in step S41; Step S43, subtracting the absorbance values at each wave number point of the aligned infrared spectra one by one to obtain a difference graph.
[0009] Furthermore, both the first aging assessment model and the second aging assessment model select BP neural network.
[0010] Furthermore, the training steps of the first aging assessment model are: Step A1, obtaining historical data of petroleum used as fuel, wherein the historical data includes infrared spectra of the petroleum before aging and infrared spectra of the petroleum at different aging periods; Step A2, preprocessing the acquired infrared spectrum, wherein the preprocessing includes: denoising, baseline correction and spectrum smoothing; Step A3, calculating a difference graph based on the infrared spectrum graph of the pre-treated oil before aging and the infrared spectrum graphs of the oil at different aging periods; Step A4, marking the difference image; Step A5, dividing the marked difference graph into a training set and a test set, training the BP neural network, and obtaining a trained first aging assessment model; the input of the BP neural network is the difference graph, and the output is the marked aging assessment result.
[0011] Furthermore, the loss function L of the first aging assessment model is 1 for: ; Among them, α and β are weight coefficients for balancing prediction accuracy and data smoothness, y pred is the aging degree predicted by the model, y true is the actual aging degree, MSE(y pred ,y true ) is the mean square error between the predicted aging degree and the actual aging degree, y preprocessed is the absorbance value after pretreatment, σ(y preprocessed ) is the standard deviation of the absorbance value after pretreatment.
[0012] Furthermore, the training steps of the second aging assessment model are: Step B1, obtaining historical data of petroleum used as a chemical raw material, wherein the historical data includes an infrared spectrum of the petroleum before aging and infrared spectrums of the petroleum at different aging periods; Step B2, preprocessing the acquired infrared spectrum, wherein the preprocessing includes: denoising, resolution improvement and data standardization; Step B3, calculating a difference graph based on the infrared spectrum graph of the pre-treated oil before aging and the infrared spectrum graphs of the oil at different aging periods; Step B4, marking the difference image; Step B5, dividing the marked difference graph into a training set and a test set, training the BP neural network, and obtaining a trained second aging assessment model; the input of the BP neural network is the difference graph, and the output is the marked aging assessment result.
[0013] Furthermore, the loss function L of the second aging assessment model is 2 for: L 2 =γ×MAE(y pred ,y true )+λ(1-R 2 (y preprocessed ,y reference )); Among them, γ and λ are the weight coefficients of equilibrium prediction accuracy and chemical composition retention degree, y pred is the aging degree predicted by the model, y true is the actual aging degree, MAE(y pred ,y true ) is the mean absolute error between the predicted aging degree and the actual aging degree, y preprocessed is the preprocessed spectral data, y referenceis the spectral data of oil before aging, R 2 (y preprocessed ,y reference ) is the coefficient of determination between the spectral data after pretreatment and the spectral data of the oil before aging.
[0014] An infrared spectrum analysis and detection device for petroleum products, the device adopts any of the above-mentioned infrared spectrum analysis and detection methods for petroleum products, and specifically comprises the following modules: A sample acquisition unit, used to acquire the oil to be tested, and the purpose of the oil to be tested; An infrared spectrum detection unit is used to detect the oil to be tested and obtain the infrared spectrum of the oil to be tested; The spectrum preprocessing unit is used to determine the preprocessing scheme of the infrared spectrum of the oil to be tested according to the purpose of the oil to be tested. If the purpose is fuel, the preprocessing means adopted are: denoising, baseline correction and spectrum smoothing; if the purpose is chemical raw materials, the preprocessing means adopted are: denoising, resolution improvement and data standardization; A difference calculation unit, used for calculating a difference graph according to the infrared spectrum graph of the pre-processed petroleum to be tested and the infrared spectrum graph of the petroleum before aging; The aging assessment unit is used to determine the model used for petroleum aging assessment according to the purpose of the petroleum to be tested, and obtain the aging assessment result of the petroleum to be tested according to the input difference map; the method for determining the model used for petroleum aging assessment is: if the purpose is fuel, select the first aging assessment model; if the purpose is chemical raw material, select the second aging assessment model.
[0015] Compared with the prior art, the beneficial effects of the present invention are: First, the present invention selects a corresponding aging assessment model according to the use of petroleum. The targeted selection can more accurately reflect the aging characteristics of petroleum with different uses, thereby improving the accuracy and reliability of aging assessment; Secondly, the present invention determines the infrared spectrum preprocessing scheme according to the purpose of petroleum. For fuel petroleum, preprocessing means such as denoising, baseline correction and spectrum smoothing are adopted to improve the accuracy and comparability of spectral data; for chemical raw material petroleum, preprocessing means such as denoising, resolution enhancement and data standardization are adopted to retain and highlight the specific chemical composition and structural information in the raw material; it can provide more accurate and reliable spectral data support for the subsequent aging assessment model, and further improve the accuracy of aging assessment; Third, the present invention designs corresponding loss functions according to the characteristics of petroleum for different uses, which can more accurately reflect the chemical and physical changes of petroleum for different uses during the aging process, thereby optimizing the training process of the aging assessment model and improving the prediction performance and generalization ability of the model. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0017] Figure 1 The present invention is a flow chart of an infrared spectrum analysis and detection method for petroleum oil products; Figure 2 The figure is a structural diagram of an infrared spectrum analysis and detection device for petroleum products. DETAILED DESCRIPTION
[0018] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be described clearly and completely below. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work belong to the scope of protection of the present invention.
[0019] The specific implementation of the present invention is described below with reference to the accompanying drawings (tables).
[0020] Example 1 like Figure 1 As shown, the present invention proposes an infrared spectrum analysis and detection method for petroleum oil products, which specifically includes steps S1-S6: Step S1, obtaining the use of the petroleum to be tested; the use includes: fuel and chemical raw material; As a widely used energy source and chemical raw material, petroleum has a variety of uses, and petroleum for different uses has significant differences in chemical composition, physical properties, and aging mechanisms. Fuel oil is mainly used for combustion to provide energy, and its aging process mainly involves reactions such as oxidation and pyrolysis, which lead to changes in properties such as increased viscosity and increased acid value. Chemical raw material petroleum is used to produce various chemicals, and its aging process may involve more complex chemical reactions, such as hydrolysis and polymerization, which have a more significant impact on chemical composition and structure.
[0021] Therefore, by classifying the oil to be tested according to its use, a more accurate pretreatment plan can be formulated for oil with different uses, and a more suitable aging assessment model can be selected, so as to more accurately assess the aging degree of the oil. This classification processing method helps to improve the accuracy and reliability of oil aging assessment and provide a more scientific and effective quality control method for the oil industry.
[0022] Step S2, obtaining an infrared spectrum of the oil to be tested and an infrared spectrum of the oil to be tested before aging; Infrared spectrum is a kind of spectrum that can reflect the internal structure and chemical bond information of material molecules. By comparing the infrared spectra of the tested oil before and after aging, the changes in the molecular structure and chemical bonds of the oil during the aging process can be observed.
[0023] By comparing the current infrared spectrum of the oil to be tested with its infrared spectrum before aging, we can more intuitively understand the chemical and physical changes that occur in the oil during storage, transportation or use, and then evaluate its aging degree and performance changes.
[0024] Step S3, determining a preprocessing scheme for the infrared spectrum according to the application; specifically: If the use is fuel, the preprocessing measures are: denoising, baseline correction and spectral smoothing; If the stated purpose is chemical raw materials, the preprocessing measures adopted are: denoising, resolution enhancement and data standardization.
[0025] Furthermore, when petroleum is used as fuel, its infrared spectral preprocessing is mainly aimed at improving the accuracy and comparability of spectral data so that the subsequent aging assessment model can accurately identify the aging components and degree in the petroleum.
[0026] Therefore, in response to the above requirements, the preprocessing methods adopted are: Denoising: to eliminate the influence of instrument noise, environmental interference and other factors on spectral data; Baseline correction: ensure that the baseline of the spectral data is stable and avoid the influence of baseline drift on the analysis results; Spectral smoothing: to reduce fluctuations and noise in the data and improve the smoothness and readability of the data.
[0027] Furthermore, when petroleum is used as a chemical raw material, its infrared spectrum preprocessing focuses more on retaining and highlighting the specific chemical composition and structural information in the raw material for subsequent analysis and processing.
[0028] Therefore, in response to the above requirements, the preprocessing methods adopted are: Fine denoising: To eliminate the influence of instrument noise, environmental interference and other factors on spectral data, the denoising method used is more complex than that of fuel oil to retain more chemical information; Spectral resolution improvement: In order to improve the ability to identify specific chemical components in chemical raw materials, it is necessary to perform resolution improvement on spectral data to make the spectral data more precise and accurate; Feature enhancement: Feature enhancement processing is performed on specific chemical components and structural information in chemical raw materials, such as enhancing the infrared absorption peak of specific functional groups, etc., to facilitate subsequent analysis and processing; Data standardization: Standardize the spectral data to ensure that the spectral data of chemical raw material petroleum from different batches and sources are comparable and consistent.
[0029] In summary, the pretreatment scheme of step S3 varies according to the different uses of petroleum. For fuel petroleum, the pretreatment scheme focuses more on improving the accuracy and comparability of spectral data; while for chemical raw material petroleum, it focuses more on retaining and highlighting the specific chemical composition and structural information in the raw material. Such a pretreatment scheme can provide more accurate and reliable spectral data support for the subsequent aging assessment model.
[0030] Step S4, calculating a difference image based on the two pre-processed infrared spectra obtained in step S3; specifically: Step S41, obtaining an infrared spectrum of the pretreated petroleum to be tested and an infrared spectrum of the pretreated petroleum before aging; Step S42, aligning the two infrared spectra obtained in step S41; Step S43, subtracting the absorbance values at each wave number point of the aligned infrared spectra one by one to obtain a difference graph.
[0031] The subtraction method can be to subtract the absorbance value at each wave number point of the infrared spectrum of the pretreated oil before aging from the absorbance value at the corresponding wave number point of the infrared spectrum of the pretreated oil to be tested, and the conclusion is retained with positive and negative signs to show the value and trend of the spectral change.
[0032] The purpose of using the difference map is to offset the inherent differences between different oil individuals, thereby highlighting the spectral changes caused by the aging process and improving the accuracy of oil aging assessment.
[0033] Step S5, selecting a model for petroleum aging assessment according to the use, specifically: if the use is fuel, selecting a first aging assessment model, if the use is chemical raw materials, selecting a second aging assessment model; Considering the complexity and nonlinear characteristics of oil aging assessment, the selection of BP neural network for the first aging assessment model and the second aging assessment model has significant advantages. With its powerful nonlinear mapping ability, self-learning and adaptive ability, BP neural network can accurately capture the nonlinear relationship in the oil aging process and achieve accurate assessment. The optimized BP neural network can better meet the needs of oil aging assessment, provide accurate and reliable assessment results, and help the oil industry understand aging conditions, extend service life, and reduce resource waste and environmental pollution.
[0034] The first aging assessment model training method is: Step A1, obtaining historical data of petroleum used as fuel, wherein the historical data includes infrared spectra of the petroleum before aging and infrared spectra of the petroleum at different aging periods; Step A2, preprocessing the acquired infrared spectrum, wherein the preprocessing includes: denoising, baseline correction and spectrum smoothing; Step A3, calculating a difference graph based on the infrared spectrum of the pretreated petroleum before aging and the infrared spectrum of the petroleum at different aging periods; the method of obtaining the difference graph here is consistent with the method of obtaining the difference graph in step S43, and the absorbance value at each wave number point of the infrared spectrum of the petroleum at different aging periods is subtracted from the absorbance value at the corresponding wave number point of the infrared spectrum of the pretreated petroleum before aging, to conclude that the positive and negative signs are retained.
[0035] Step A4, marking the difference image; Step A5, dividing the marked difference graph into a training set and a test set, training the BP neural network, and obtaining a trained first aging assessment model; the input of the BP neural network is the difference graph, and the output is the marked aging assessment result.
[0036] For fuel oil, the preprocessing methods mainly include denoising, baseline correction and spectral smoothing. Considering that these preprocessing steps are aimed at improving the accuracy and comparability of spectral data, we can design a loss function that not only considers the difference between the model prediction results and the actual aging degree, but also considers the smoothness and stability of the spectral data after preprocessing.
[0037] Therefore, the loss function L of the first aging assessment model is 1 for: ; Among them, α and β are weight coefficients to balance prediction accuracy and data smoothness; y pred is the aging degree predicted by the model, y true For the true degree of aging; MSE(y pred ,y true ) is the mean square error between the predicted aging degree and the actual aging degree, which is used to measure the accuracy of model prediction; y preprocessed is the absorbance value after pretreatment, σ(y preprocessed ) is the standard deviation of the absorbance value after preprocessing, which is used to measure the smoothness and stability of the data.
[0038] Furthermore, the second aging assessment model training method is: Step B1, obtaining historical data of petroleum used as a chemical raw material, wherein the historical data includes an infrared spectrum of the petroleum before aging and infrared spectrums of the petroleum at different aging periods; Step B2, preprocessing the acquired infrared spectrum, wherein the preprocessing includes: denoising, resolution improvement and data standardization; Step B3, calculating a difference graph based on the infrared spectrum graph of the pre-treated oil before aging and the infrared spectrum graphs of the oil at different aging periods; Step B4, marking the difference image; Step B5, dividing the marked difference graph into a training set and a test set, training the BP neural network, and obtaining a trained second aging assessment model; the input of the BP neural network is the difference graph, and the output is the marked aging assessment result.
[0039] For chemical raw materials such as petroleum, the preprocessing methods mainly include denoising, resolution enhancement, and data normalization. Since these preprocessing steps are designed to retain and highlight the specific chemical composition and structural information in the raw materials, we can design a loss function that considers not only the accuracy of the model prediction but also the degree of retention of specific chemical components in the spectral data after preprocessing.
[0040] Therefore, the loss function L of the second aging assessment model is 2 for: L 2 =γ×MAE(y pred ,y true )+λ(1-R 2 (y preprocessed ,y reference )); Among them, γ and λ are the weight coefficients of equilibrium prediction accuracy and chemical composition retention degree; y pred is the aging degree predicted by the model, y true The true degree of aging MAE(y pred ,y true ) is the mean absolute error between the predicted aging degree and the actual aging degree, which is used to measure the accuracy of model prediction. MAE is chosen here instead of MSE because MAE is less sensitive to outliers and more suitable for the complexity and diversity of chemical raw materials petroleum; y preprocessed is the preprocessed spectral data, y reference The spectral data of the oil before aging is used as the known data for reference; R 2 (y preprocessed ,y reference) is the coefficient of determination between the spectral data after pretreatment and the spectral data of the oil before aging, which is used to measure the degree of retention of specific chemical components. It is a well-known calculation method and will not be described in detail here.
[0041] Both loss functions are customized according to the specific needs of petroleum aging assessment, aiming to improve the prediction accuracy and applicability of the model under different preprocessing methods. The weight coefficients (α, β, γ, λ) can be set based on experience or obtained through experimental data analysis.
[0042] Step S6, inputting the difference map into the trained aging assessment model, and outputting the aging assessment result of the tested petroleum.
[0043] The evaluation results can be set as needed, such as aging grade, aging stage, etc., and transportation and storage recommendations can also be added. The same aging degree may not necessarily correspond to the same aging grade for oil with different uses, so using different models to evaluate them separately can significantly improve the accuracy of the evaluation.
[0044] According to the input difference map, the aging components and degree of oil are automatically identified, and the corresponding aging evaluation results are given. It helps enterprises to understand the aging of oil in a timely manner and take corresponding measures to extend the service life of oil, reduce resource waste and environmental pollution. At the same time, this evaluation result can also provide strong data support for the quality control and research and development of oil products.
[0045] In view of the problem that the existing petroleum aging assessment methods do not distinguish the assessment methods according to the use of petroleum, and adopt a unified large model for aging assessment, resulting in inaccurate assessment results, the present invention proposes an infrared spectrum analysis and detection method and detection device for petroleum products. The method includes obtaining the use of the petroleum to be tested, obtaining the infrared spectrum of the petroleum to be tested and before aging, determining a preprocessing scheme of the infrared spectrum according to the use, calculating a difference map of the infrared spectrum after preprocessing, selecting a model for petroleum aging assessment, and inputting the difference map into a trained aging assessment model, and outputting the aging result of the petroleum to be tested. The aging degree of the petroleum can be evaluated more specifically, and the accuracy of the assessment result is improved.
[0046] Example 2 like Figure 2 As shown, the present invention also proposes an infrared spectrum analysis and detection device for petroleum products, which is used to implement an infrared spectrum analysis and detection method for petroleum products as described in any one of Embodiment 1, and includes the following modules: A sample acquisition unit, used to acquire the oil to be tested, and the purpose of the oil to be tested; An infrared spectrum detection unit is used to detect the oil to be tested and obtain the infrared spectrum of the oil to be tested; The spectrum preprocessing unit is used to determine the preprocessing scheme of the infrared spectrum of the oil to be tested according to the purpose of the oil to be tested. If the purpose is fuel, the preprocessing means adopted are: denoising, baseline correction and spectrum smoothing; if the purpose is chemical raw materials, the preprocessing means adopted are: denoising, resolution improvement and data standardization; A difference calculation unit, used for calculating a difference graph according to the infrared spectrum graph of the pre-processed petroleum to be tested and the infrared spectrum graph of the petroleum before aging; The aging assessment unit is used to determine the model used for petroleum aging assessment according to the purpose of the petroleum to be tested, and obtain the aging assessment result of the petroleum to be tested according to the input difference map; the method for determining the model used for petroleum aging assessment is: if the purpose is fuel, select the first aging assessment model; if the purpose is chemical raw material, select the second aging assessment model.
[0047] Example 3 An electronic device, comprising: Processor and memory; The processor is used to execute the steps of the infrared spectroscopy analysis and detection method for petroleum products as described in any one of Example 1 by calling the program or instructions stored in the memory.
[0048] Example 4 A computer-readable storage medium, the computer-readable storage medium comprising computer program instructions, the computer program instructions causing a computer to execute the steps of the infrared spectroscopy analysis and detection method for petroleum products as described in any one of Example 1.
[0049] The computer readable storage medium can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0050] It should be noted that the terms used in the present invention are only for describing specific embodiments, rather than limiting the scope of the present invention. As shown in the present specification, unless the context clearly indicates an exception, the words "one", "a", "a kind of" and / or "the" do not specifically refer to the singular, but may also include the plural. The terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method or device. In the absence of more restrictions, the elements defined by the sentence "include one..." do not exclude the presence of other identical elements in the process, method or device including the elements.
[0051] It should also be noted that the terms "center", "up", "down", "left", "right", "vertical", "horizontal", "inside", "outside", etc., indicating the orientation or positional relationship, are based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present invention. Unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", etc. should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be an indirect connection through an intermediate medium, or it can be a connection between the two elements. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0052] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the technical solutions of the embodiments of the present invention.
Claims
1. A method for infrared spectroscopy analysis and detection of petroleum oil products, characterized in that: The steps include: Step S1, obtaining the use of the petroleum to be tested; the use includes: fuel and chemical raw material; Step S2, obtaining an infrared spectrum of the oil to be tested and an infrared spectrum of the oil to be tested before aging; Step S3, determining a preprocessing scheme of the infrared spectrum according to the purpose; Step S4, calculating a difference image according to the two pre-processed infrared spectra obtained in step S3; Step S5, selecting a model for petroleum aging assessment according to the use, specifically: if the use is fuel, selecting a first aging assessment model, if the use is chemical raw materials, selecting a second aging assessment model; Step S6, inputting the difference map into the trained aging assessment model, and outputting the aging assessment result of the tested petroleum.
2. The infrared spectrum analysis and detection method for petroleum oil products according to claim 1, characterized in that: In step S3, the preprocessing scheme of the infrared spectrum is determined according to the purpose, specifically: If the use is fuel, the preprocessing measures are: denoising, baseline correction and spectral smoothing; If the stated purpose is chemical raw materials, the preprocessing measures adopted are: denoising, resolution enhancement and data standardization.
3. The infrared spectrum analysis and detection method for petroleum oil products according to claim 1, characterized in that: In step S4, a difference graph is calculated based on the two pre-processed infrared spectra, specifically: Step S41, obtaining an infrared spectrum of the pretreated petroleum to be tested and an infrared spectrum of the pretreated petroleum before aging; Step S42, aligning the two infrared spectra obtained in step S41; Step S43, subtracting the absorbance values at each wave number point of the aligned infrared spectra one by one to obtain a difference graph.
4. The infrared spectrum analysis and detection method for petroleum oil products according to claim 1, characterized in that: The first aging assessment model and the second aging assessment model both select BP neural network.
5. The infrared spectrum analysis and detection method for petroleum oil products according to claim 1, characterized in that: The training steps of the first aging assessment model are: Step A1, obtaining historical data of petroleum used as fuel, wherein the historical data includes infrared spectra of the petroleum before aging and infrared spectra of the petroleum at different aging periods; Step A2, preprocessing the acquired infrared spectrum, wherein the preprocessing includes: denoising, baseline correction and spectrum smoothing; Step A3, calculating a difference graph based on the infrared spectrum graph of the pre-treated oil before aging and the infrared spectrum graphs of the oil at different aging periods; Step A4, marking the difference image; Step A5, dividing the marked difference graph into a training set and a test set, training the BP neural network, and obtaining a trained first aging assessment model; the input of the BP neural network is the difference graph, and the output is the marked aging assessment result.
6. The infrared spectrum analysis and detection method for petroleum oil products according to claim 1, characterized in that: The loss function L1 of the first aging assessment model is: ; Among them, α and β are weight coefficients for balancing prediction accuracy and data smoothness, y pred is the aging degree predicted by the model, y true is the actual aging degree, MSE(y pred ,y true ) is the mean square error between the predicted aging degree and the actual aging degree, y preprocessed is the absorbance value after pretreatment, σ(y preprocessed ) is the standard deviation of the absorbance value after pretreatment.
7. The infrared spectrum analysis and detection method for petroleum oil products according to claim 1, characterized in that: The training steps of the second aging assessment model are: Step B1, obtaining historical data of petroleum used as a chemical raw material, wherein the historical data includes an infrared spectrum of the petroleum before aging and infrared spectrums of the petroleum at different aging periods; Step B2, preprocessing the acquired infrared spectrum, wherein the preprocessing includes: denoising, resolution improvement and data standardization; Step B3, calculating a difference graph based on the infrared spectrum graph of the pre-treated oil before aging and the infrared spectrum graphs of the oil at different aging periods; Step B4, marking the difference image; Step B5, dividing the marked difference graph into a training set and a test set, training the BP neural network, and obtaining a trained second aging assessment model; the input of the BP neural network is the difference graph, and the output is the marked aging assessment result.
8. The infrared spectrum analysis and detection method for petroleum oil products according to claim 1, characterized in that: The loss function L2 of the second aging assessment model is: L2=γ×MAE(and pred ,and true )+λ(1-R 2 (and preprocessed ,and reference )); Among them, γ and λ are the weight coefficients of equilibrium prediction accuracy and chemical composition retention degree, y pred is the aging degree predicted by the model, y true is the actual aging degree, MAE(y pred ,y true ) is the mean absolute error between the predicted aging degree and the actual aging degree, y preprocessed is the preprocessed spectral data, y reference is the spectral data of oil before aging, R 2 (y preprocessed ,y reference ) is the coefficient of determination between the spectral data after pretreatment and the spectral data of the oil before aging.
9. An infrared spectrum analysis and detection device for petroleum oil products, characterized in that: The device adopts the infrared spectrum analysis and detection method of petroleum oil products according to any one of claims 1 to 8, and specifically comprises the following units: A sample acquisition unit, used to acquire the oil to be tested, and the purpose of the oil to be tested; An infrared spectrum detection unit is used to detect the oil to be tested and obtain the infrared spectrum of the oil to be tested; The spectrum preprocessing unit is used to determine the preprocessing scheme of the infrared spectrum of the oil to be tested according to the purpose of the oil to be tested. If the purpose is fuel, the preprocessing means adopted are: denoising, baseline correction and spectrum smoothing; if the purpose is chemical raw materials, the preprocessing means adopted are: denoising, resolution improvement and data standardization; A difference calculation unit, used for calculating a difference graph according to the infrared spectrum graph of the pre-processed petroleum to be tested and the infrared spectrum graph of the petroleum before aging; The aging assessment unit is used to determine the model used for petroleum aging assessment according to the purpose of the petroleum to be tested, and obtain the aging assessment result of the petroleum to be tested according to the input difference map; the method for determining the model used for petroleum aging assessment is: if the purpose is fuel, select the first aging assessment model; if the purpose is chemical raw material, select the second aging assessment model.
Citation Information
Patent Citations
Insulation paper type discrimination method based on near infrared spectrum principal component analysis
CN109781658A
Transformer solid insulating material aging state evaluation method
CN111126497A
Near-infrared spectroscopic analysis detection device and detection method for petroleum products
CN114088655A
Asphalt aging evaluation method and device
CN117852408A
Near infrared spectrum method, system, medium and device for qualitative judgment of oil product types
CN118603930A
Cited By
Near infrared spectrum interference correction method and system for vehicle gasoline detection
CN120084755A
Method and system for evaluating thermal stability of millet diglyceride oil
CN120741399A
