Energy spectrum analysis method based on sample migration
Through the method of feature and label alignment, simulated data and measured data are mapped to the shared subspace, and an energy spectrum classification model is constructed, which solves the problem of difficulty in obtaining radionuclide γ energy spectrum samples, and realizes data expansion and model reliability improvement.
Patent Information
- Application Number
- CN202510527567.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-25
- Publication Date
- 2025-08-08
AI Technical Summary
In the prior art, it is difficult to obtain radionuclide gamma spectrum samples, and the simulated data cannot fully replicate the real measurement environment, resulting in unreliable model and ineffective sample expansion method.
By aligning the Monte Carlo numerical simulation data and measured data, a low-count energy spectrum classification model is built to achieve data expansion.
Effectively expand the amount of energy spectrum data, reduce the dependence on actual measured annotated data, improve model reliability, and solve the problem of low-count γ energy spectrum recognition in small samples.
Smart Images

Figure CN120452601A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of nuclear radiation detection, and more particularly to the technical field of an energy spectrum analysis method based on sample migration. Background Art
[0002] The evolving nature of modern machine learning methods requires an increasing number of labeled samples, but the actual process of acquiring radionuclide spectra is cumbersome and inherently dangerous. To minimize the risk of operator harm from radioactive experiments, operators must undergo adequate skill training and protective measures. To ensure the quality of gamma-ray spectra and reduce errors in spectral analysis, multiple measurements of the gamma-ray source are typically required, while ensuring sufficient counts. This time-consuming process requires strict control of measurement geometry, including the relative position of the detector and sample, ambient temperature, and detector operating voltage.
[0003] Therefore, it takes a certain amount of time and effort to obtain each radionuclide gamma spectrum sample. The actual number of radionuclide gamma spectrum samples available for research is relatively small, and no widely used public data sets have been found.
[0004] To address this issue, most researchers use Monte Carlo-based particle simulation tools such as Geant4 (GEometry ANdTracking) or MCNP (Monte Carlo N-Particle Transport) to simulate the physical process of gamma photon transport in matter, obtaining simulated gamma energy spectra of radionuclides for study. Simulated gamma energy spectra can display the energy spectrum curves and peak position characteristics of different radionuclides. However, due to the highly idealized simulation environment, the simulated data cannot fully replicate the various interferences and contributions in the actual measurement environment. While they can serve as a theoretical research target to a certain extent, they cannot completely replace the measured energy spectra.
[0005] Another group of researchers has expanded radionuclide gamma spectrum samples through data processing. This type of sample expansion method simply copies and modifies the original sample, without measuring whether the expanded sample is beneficial for training the target model, and is not necessarily helpful for constructing the target model. Summary of the Invention
[0006] The purpose of the present invention is to solve the above technical problems and provide a spectrum analysis method based on sample migration. This method avoids the problem of unreliable model caused by insufficient number of labeled samples and provides a new solution for the problem of small sample low count gamma spectrum identification in rapid measurement scenarios.
[0007] In order to achieve the above-mentioned purpose, the present invention specifically adopts the following technical solutions:
[0008] The present invention provides an energy spectrum analysis method based on sample migration, comprising the following steps:
[0009] S1. A large amount of simulated radionuclide γ spectrum data obtained by Monte Carlo numerical simulation method is used as the source domain;
[0010] S2. Using a small amount of labeled measured radionuclide gamma spectrum data obtained by measuring the radioactive source through the detector as the target domain;
[0011] S3, through feature alignment, maps the source domain and target domain samples with heterogeneous data distribution into a shared subspace with discriminative feature representation;
[0012] S4. Align source and target domain samples with heterogeneous label spaces through label alignment;
[0013] S5. Construct a classification model of low count energy spectrum through tree decision making.
[0014] In one embodiment, in step S1, a three-dimensional space coordinate system is constructed in MCNP, and a spherical shielding system with a radius of 100 cm is set with the origin as the center to terminate the particle tracking process in time and reduce unnecessary computing resource consumption; the internal medium of the spherical shielding system is air with a density of 0.001293 g / cm 3 (i.e. 1.293kg / m 3 ), the outside of the spherical shielding system is a vacuum to simulate an ideal environment without dielectric influence; since the actual volume of the radioactive source used in the actual measurement experiment is usually smaller than the crystal used, it is simplified to a point source in the modeling process, that is, its physical size is ignored and only its radiation characteristics are considered; the radioactive source is placed at the origin, and different detection time parameters, shielding conditions and other parameters are set to obtain a large number of simulated energy spectrum samples.
[0015] In one embodiment, an open experimental area that meets safety standards is selected as a fixed experimental operation point; to accurately measure the relative distance between the energy spectrometer and various radiation sources, a ruler is placed on the ground in the experimental area to ensure that the radiation source is accurately positioned at the origin of the ruler; and measured energy spectrum samples are obtained by setting parameters such as measurement distance, measurement duration, and measurement angle.
[0016] In one embodiment, in step S3, source domain and target domain samples with heterogeneous data distribution are mapped to a shared subspace with discriminative feature representation through feature alignment. The specific process is as follows:
[0017] S31, taking the energy domain as the object, cutting the energy spectrum samples from the source domain and the target domain into multiple energy segments in the energy domain;
[0018] S32. Selecting a Compton plateau, a characteristic peak, and an auxiliary peak in the energy domain according to the decay characteristics of the radioactive nuclides in the target domain, and obtaining a characteristic peak-to-plateau ratio and a characteristic peak-to-peak ratio;
[0019] S33. The scale-transformed heterogeneous simulated samples and measured samples and the corresponding characteristic peak-to-flat ratios and characteristic peak-to-peak ratios are used as discriminative feature expression components in the shared subspace.
[0020] In one embodiment, in step S31, the dimensions of the samples are grouped and reorganized according to the scale parameter c. c The data are divided into units to form heterogeneous simulated samples and measured samples after scale transformation and projection into low-dimensional space.
[0021] In one embodiment, heterogeneous simulated samples and measured samples are denoted as The formula is as follows:
[0022]
[0023] Where c is the scale parameter, d is the sample dimension, d∈N + ; x is the sample, i is the traversal of the sample address, and b is the identifier of the low-dimensional space, that is, Represents the value of sample x at the i-th address in the low-dimensional space.
[0024] In one embodiment, in step S32, the formula for the characteristic peak-to-plateau ratio is: The formula for the characteristic peak-to-peak ratio is:
[0025] Where i is the serial number of a specific address, j is the serial number of a specific address, e is the characteristic energy value, e′ is the auxiliary energy value, E is the energy domain range of the energy spectrum sample, c l and c r Represent the left and right boundaries of Compton Flat respectively
[0026] In one embodiment, in step S4, the source domain and target domain samples with heterogeneous label spaces are aligned by label alignment. The specific process is as follows:
[0027] S41, calculating the centroid vector of each category in the target domain;
[0028] S42, using the target domain centroid to initialize the source domain sample cluster centroid;
[0029] S43, assigning source domain samples to the nearest cluster according to the distance between the source domain samples and the initial centroid;
[0030] S44, update the centroid within the cluster, and repeat steps S41 to S43 until the centroid position is optimized or the number of iterations is reached;
[0031] S45. Set a distance threshold to remove source domain samples that are too far away from the cluster centroid;
[0032] S46. Reassign the category labels of the migrated source domain samples according to the target domain category labels corresponding to the cluster centroids.
[0033] In one embodiment, in step S41, the centroid vectors of each category in the target domain are calculated in the following manner:
[0034] Represents a set of m target domain samples, where the non-repeated label set is expressed as:
[0035] In the formula, t is the identifier of the target domain, x is the sample in the target domain, y is the category label corresponding to the sample, j = 1…m, which represents the traversal of the samples in the set; further, the set of labels of the target domain samples is The set of non-repeated labels in is represented as U, u1, u2, ..., u k Represents k non-repeated category labels, where each u k is a non-repeating category label.
[0036] The category label is u k The target domain sample set is represented as T k : Then the sample set T k The centroid vector μ k It can be expressed as:
[0037] Where, T k Represents all categories labeled u k The set of target domain samples, and the set T k Each sample in All belong to the target domain T t . Represents the screening condition, that is, the category label of the sample is u k .
[0038] μ k Represents the sample set T k The centroid vector of |T k | represents the set T k The number of samples in the medium. Represents the set T k The successive accumulation of all sample feature vectors in .
[0039] In one embodiment, in step S42, the source domain sample cluster centroid is initialized using the target domain centroid;
[0040] The source domain samples are divided into k clusters, and the initial centroid of the cluster is
[0041] Where k is the number of clusters into which the source domain samples are divided, (0) is used to identify the initial centroid, and j = 1…k represents the traversal of the initial centroid;
[0042] In step S43, the source domain samples are assigned to the nearest cluster according to the distance from the source domain samples to the initial centroid:
[0043]
[0044] Where C j It means that after calculating the distance from each source domain sample to each centroid, it is assigned to the cluster formed by the nearest initial centroid. To form the jth cluster C j Source domain samples The screening conditions, μ j and μ l Represents different centers of mass, i.e. “l≠j”. Represents the distance from the i-th sample to the j-th centroid in the source domain. Similarly, Represents the distance from the i-th sample to the l-th centroid in the source domain. Where i, j, and l represent the traversal of source domain samples, clusters, and centroids, respectively.
[0045] In step S44, the centroid of the cluster is updated: Repeat this process until the center of mass is in the optimal position.
[0046] Optimize or reach the number of iterations, the optimization goal is:
[0047]
[0048] Where, Represents the j-th cluster centroid μ j The update process of |C j | represents cluster C j The number of samples in Represents cluster C j The i-th source domain sample, Represents cluster C j The successive accumulation of all sample feature vectors in .
[0049] The goal and constraints of the centroid update are shown in the above formula, that is, to minimize the sum of the distances between the samples in the cluster and the centroid of the cluster, C j is the jth cluster, μ jis the jth centroid, j = 1…k, indicating the traversal of clusters and centroids;
[0050] Among the constraints, is the jth initial centroid, and ε is a very small constant.
[0051] In step S45, a distance threshold is set to remove source domain samples that are too far away from the cluster centroid;
[0052] Calculate the distance from the sample to the centroid: On this basis, source domain samples are screened to obtain the filtered source domain sample set:
[0053] Where, d ij is the distance from the i-th sample to the j-th centroid; is the i-th sample in the source domain, μ j is the jth centroid; C′ j is the filtered source domain sample set, which contains multiple source domain samples θ is a pre-set distance threshold.
[0054] In step S46, the category labels of the migrated source domain samples are redistributed according to the target domain category labels corresponding to the cluster centroids:
[0055] In the formula, the new category label of the i-th source domain sample in the filtered source domain sample set is The target domain category label μ corresponding to the centroid of the filtered source domain sample set j .
[0056] The beneficial effects of the present invention are as follows:
[0057] The present invention is rationally designed and can effectively expand the number of energy spectra through simulated energy spectrum data with heterogeneous data distribution and label space. It can reduce the strong dependence of the classification model on a large amount of measured labeled data, avoid the model unreliability problem caused by insufficient number of labeled samples, and provide a new solution to the problem of small-sample low-count gamma energy spectrum recognition in rapid measurement scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following is a brief introduction to the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can be obtained based on these drawings without paying any creative work.
[0059] Figure 1 It is a flow chart of an energy spectrum analysis method based on sample migration according to the present invention.
[0060] Figure 2 It is a flow chart of the feature alignment process of the present invention.
[0061] Figure 3 It is a flowchart of the label alignment process of the present invention. DETAILED DESCRIPTION
[0062] To make the technical problems, technical solutions, and technical effects of the present invention more clear, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings herein can be arranged and designed in various different configurations.
[0063] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention as claimed, but rather merely represents selected embodiments of the present invention. All other embodiments derived by persons of ordinary skill in the art based on the embodiments of the present invention without creative effort are intended to fall within the scope of protection of the present invention.
[0064] Example 1
[0065] like Figure 1 As shown, this embodiment provides an energy spectrum analysis method based on sample migration, including the following process:
[0066] A method for energy spectrum analysis based on sample migration includes the following steps:
[0067] S1. A large amount of simulated radionuclide γ spectrum data obtained by Monte Carlo numerical simulation method is used as the source domain;
[0068] A three-dimensional coordinate system was constructed in MCNP, and a spherical shielding system with a radius of 100 cm was set up with the origin as the center to terminate the particle tracking process in time and reduce unnecessary computing resource consumption; the internal medium of the spherical shielding system was air with a density of 0.001293 g / cm 3 (i.e. 1.293kg / m 3 ), the outside of the spherical shielding system is a vacuum to simulate an ideal environment without dielectric influence; since the actual volume of the radioactive source used in the actual measurement experiment is usually smaller than the crystal used, it is simplified to a point source in the modeling process, that is, its physical size is ignored and only its radiation characteristics are considered; the radioactive source is placed at the origin, and different detection time parameters, shielding conditions and other parameters are set to obtain a large number of simulated energy spectrum samples.
[0069] S2. Using a small amount of labeled measured radionuclide gamma spectrum data obtained by measuring the radioactive source through the detector as the target domain;
[0070] An open experimental area that meets safety standards is selected as the fixed operating point of the experiment. In order to accurately measure the relative distance between the energy spectrometer and various radiation sources, a ruler is placed on the ground of the experimental area to ensure that the radiation source is accurately positioned at the origin of the ruler. The measured energy spectrum samples are obtained by setting parameters such as measurement distance, measurement time, and measurement angle.
[0071] S3. Map the heterogeneous source and target domain samples into a shared subspace with discriminative feature representations through feature alignment. The specific process is as follows:
[0072] S31, taking the energy domain as the object, cutting the energy spectrum samples from the source domain and the target domain into multiple energy segments on the energy domain; through the grouping and reorganization operation controlled by the scale parameter c, the dimension of the sample is divided into 2 c The units are divided to form heterogeneous simulated samples and measured samples after scale transformation projected into low-dimensional space; the heterogeneous simulated samples and measured samples are recorded as The formula is as follows:
[0073]
[0074] Where c is the scale parameter, d is the sample dimension, d∈N + ; x is the sample, i is the traversal of the sample address, and b is the identifier of the low-dimensional space, that is, Represents the value of sample x at the i-th address in the low-dimensional space.
[0075] S32. Selecting a Compton plateau, a characteristic peak, and an auxiliary peak in the energy domain according to the decay characteristics of the radioactive nuclides in the target domain, and obtaining a characteristic peak-to-plateau ratio and a characteristic peak-to-peak ratio;
[0076] The formula for the characteristic peak-to-plateau ratio is: The formula for the characteristic peak-to-peak ratio is:
[0077] Where i is the serial number of a specific address, j is the serial number of a specific address, e is the characteristic energy value, e′ is the auxiliary energy value, E is the energy domain range of the energy spectrum sample, c l and c t Represent the left and right boundaries of Compton Flat respectively
[0078] S33. The scale-transformed heterogeneous simulated samples and measured samples and the corresponding characteristic peak-to-flat ratios and characteristic peak-to-peak ratios are used as discriminative feature expression components in the shared subspace.
[0079] Label alignment is used to align source and target domain samples with heterogeneous label spaces. The specific process is as follows:
[0080] S41. Calculate the centroid vector of each category in the target domain; the specific method is as follows:
[0081] Represents a set of m target domain samples, where the non-repeated label set is expressed as:
[0082] In the formula, t is the identifier of the target domain, x is the sample in the target domain, y is the category label corresponding to the sample, j = 1…m, which represents the traversal of the samples in the set; further, the set of labels of the target domain samples is The set of non-repeated labels in is represented as U, u1, u2, ..., u k Represents k non-repeated category labels, where each u k is a non-repeating category label.
[0083] The category label is u k The target domain sample set is represented as T k : Then the sample set T k The centroid vector μ k It can be expressed as:
[0084]
[0085] Where, T k Represents all categories labeled u k The set of target domain samples, and the set T k Each sample in All belong to the target domain T t . Represents the screening condition, that is, the category label of the sample is u k .
[0086] μ k Represents the sample set T k The centroid vector of |T k | represents the set T k The number of samples in the medium. Represents the set T k The successive accumulation of all sample feature vectors in .
[0087] S42, using the target domain centroid to initialize the source domain sample cluster centroid;
[0088] The source domain samples are divided into k clusters, and the initial centroid of the cluster is
[0089] Where k is the number of clusters into which the source domain samples are divided, (0) is used to identify the initial centroid, and j = 1…k represents the traversal of the initial centroid;
[0090] S43, assigning source domain samples to the nearest cluster according to the distance between the source domain samples and the initial centroid;
[0091]
[0092] Where C j It means that after calculating the distance from each source domain sample to each centroid, it is assigned to the cluster formed by the nearest initial centroid. To form the jth cluster C j Source domain samples The screening conditions, μ j and μ l Represents different centers of mass, i.e. “l≠j”. Represents the distance from the i-th sample to the j-th centroid in the source domain. Similarly, Represents the distance from the i-th sample to the l-th centroid in the source domain. Where i, j, and l represent the traversal of source domain samples, clusters, and centroids, respectively.
[0093] S44, update the centroid within the cluster, and repeat steps S41 to S43 until the centroid position is optimized or the number of iterations is reached;
[0094] Update the centroids within the cluster: Repeat this process until the centroid position is optimized or the iteration
[0095] times, the optimization goal is:
[0096]
[0097] Where, Represents the j-th cluster centroid μ j The update process of |C j | represents cluster C j The number of samples in Represents cluster C j The i-th source domain sample, Represents cluster C j The successive accumulation of all sample feature vectors in .
[0098] The goal and constraints of the centroid update are shown in the above formula, that is, to minimize the sum of the distances between the samples in the cluster and the centroid of the cluster, C j is the jth cluster, μ j is the jth centroid, j = 1…k, indicating the traversal of clusters and centroids;
[0099] Among the constraints, is the jth initial centroid, and ε is a very small constant.
[0100] S45. Set a distance threshold to remove source domain samples that are too far away from the cluster centroid;
[0101] Calculate the distance from the sample to the centroid: On this basis, source domain samples are screened to obtain the filtered source domain sample set:
[0102] Where, d ij is the distance from the i-th sample to the j-th centroid; is the i-th sample in the source domain, μ j is the jth centroid; C′ j is the filtered source domain sample set, which contains multiple source domain samples θ is a pre-set distance threshold.
[0103] S46. Reassign the category labels of the migrated source domain samples according to the target domain category labels corresponding to the cluster centroids:
[0104] In the formula, the new category label of the i-th source domain sample in the filtered source domain sample set is The target domain category label μ corresponding to the centroid of the filtered source domain sample set j .
[0105] S5. Construct a classification model of low count energy spectrum through tree decision making;
[0106] Decision trees were used for classification model construction, the maximum depth of the tree was limited to 20, and the splitting criterion was the Gini diversity index.
Claims
1. A spectrum analysis method based on sample migration, characterized in that: The steps include: S1. A large amount of simulated radionuclide γ spectrum data obtained by Monte Carlo numerical simulation method is used as the source domain; S2. Using the labeled measured radionuclide gamma spectrum data obtained by measuring the radioactive source through the detector as the target domain; S3, through feature alignment, maps the source domain and target domain samples with heterogeneous data distribution into a shared subspace with discriminative feature representation; S4. Align source and target domain samples with heterogeneous label spaces through label alignment; S5. Construct a classification model of low count energy spectrum through tree decision making.
2. The energy spectrum analysis method based on sample migration according to claim 1, characterized in that: In step S1, a three-dimensional spatial coordinate system is constructed in MCNP, and a spherical shielding system is set up with the origin as the center to terminate the particle tracking process in time and reduce unnecessary computing resource consumption; the internal medium of the spherical shielding system is air, and the external medium of the spherical shielding system is vacuum to simulate an ideal environment without medium influence; different detection time and shielding conditions are set to obtain a large number of simulated energy spectrum samples.
3. The energy spectrum analysis method based on sample migration according to claim 1, characterized in that: In step S2, an open experimental area that meets safety standards is selected as a fixed operating point for the experiment. To accurately measure the relative distance between the energy spectrometer and various radiation sources, a ruler is placed on the ground in the experimental area to ensure that the radiation source is accurately positioned at the origin of the ruler. The measured energy spectrum samples are obtained by setting the measurement distance, measurement time, and measurement angle.
4. The energy spectrum analysis method based on sample migration according to claim 1, characterized in that: In step S3, feature alignment is used to map the heterogeneous source and target domain samples into a shared subspace with discriminative feature representation. The specific process is as follows: S31, taking the energy domain as the object, cutting the energy spectrum samples from the source domain and the target domain into multiple energy segments in the energy domain; S32. Selecting a Compton plateau, a characteristic peak, and an auxiliary peak in the energy domain according to the decay characteristics of the radioactive nuclides in the target domain, and obtaining a characteristic peak-to-plateau ratio and a characteristic peak-to-peak ratio; S33. The scale-transformed heterogeneous simulated samples and measured samples and the corresponding characteristic peak-to-flat ratios and characteristic peak-to-peak ratios are used as discriminative feature expression components in the shared subspace.
5. The energy spectrum analysis method based on sample migration according to claim 4, characterized in that: In step S31, the sample dimensions are divided into 2 c The data are divided into units to form heterogeneous simulated samples and measured samples after scale transformation and projection into low-dimensional space.
6. The energy spectrum analysis method based on sample migration according to claim 5, characterized in that: Heterogeneous simulated samples and measured samples are denoted as The formula is as follows: Where c is the scale parameter, d is the sample dimension, d∈N + ; x is the sample, i is the traversal of the sample address, and b is the identifier of the low-dimensional space, that is, Represents the value of sample x at the i-th address in the low-dimensional space.
7. The energy spectrum analysis method based on sample migration according to claim 4, characterized in that: In step S32, the formula for the characteristic peak-to-plateau ratio is: The formula for the characteristic peak-to-peak ratio is: Where i is the serial number of a specific address, j is the serial number of a specific address, e is the characteristic energy value, e′ is the auxiliary energy value, E is the energy domain range of the energy spectrum sample, c l and c r Represent the left and right boundaries of Compton Flat respectively 8. The energy spectrum analysis method based on sample migration according to claim 1, characterized in that: In step S4, the source domain and target domain samples with heterogeneous label spaces are aligned through label alignment. The specific process is as follows: S41, calculating the centroid vector of each category in the target domain; S42, using the target domain centroid to initialize the source domain sample cluster centroid; S43, assigning source domain samples to the nearest cluster according to the distance between the source domain samples and the initial centroid; S44, update the centroid within the cluster, and repeat steps S41 to S43 until the centroid position is optimized or the number of iterations is reached; S45. Set a distance threshold to remove source domain samples that are too far away from the cluster centroid; S46. Reassign the category labels of the migrated source domain samples according to the target domain category labels corresponding to the cluster centroids.
9. The energy spectrum analysis method based on sample migration according to claim 8, characterized in that: In step S41, the centroid vectors of each category in the target domain are calculated as follows: Represents a set of m target domain samples, where the non-repeated label set is expressed as: In the formula, t is the identifier of the target domain, x is the sample in the target domain, y is the category label corresponding to the sample, j = 1…m, which represents the traversal of the samples in the set; further, the set of labels of the target domain samples is The set of non-repeated labels in is represented as U, u1, u2, ..., u k Represents k non-repeated category labels, where each u k is a non-repeating category label; The category label is u k The target domain sample set is represented as T k : Then the sample set T k The centroid vector μ k It can be expressed as: Where, T k Represents all categories labeled u k The set of target domain samples, and the set T k Each sample in All belong to the target domain T t ; Represents the screening condition, that is, the category label of the sample is u k ; μ k Represents the sample set g k The centroid vector of |T k | represents the set T k The number of samples in the medium; Represents the set T k The successive accumulation of all sample feature vectors in .
10. The energy spectrum analysis method based on sample migration according to claim 8, characterized in that: In step S42, the centroid of the source domain sample cluster is initialized using the centroid of the target domain; The source domain samples are divided into k clusters, and the initial centroid of the cluster is Where k is the number of clusters into which the source domain samples are divided, (0) is used to identify the initial centroid, and j = 1…k represents the traversal of the initial centroid; In step S43, the source domain samples are assigned to the nearest cluster according to the distance from the source domain samples to the initial centroid: Where C j It means that after calculating the distance from each source domain sample to each centroid, it is assigned to the cluster formed by the nearest initial centroid; To form the jth cluster C j Source domain samples The screening conditions, μ j and μ l represents different centers of mass, i.e. "l≠j"; Represents the distance from the i-th sample to the j-th centroid in the source domain. Similarly, represents the distance from the i-th sample to the l-th centroid in the source domain; where i, j, and l represent the traversal of source domain samples, clusters, and centroids, respectively; In step S44, the centroid of the cluster is updated: Repeat this process until the centroid position is optimized or the number of iterations is reached. The optimization goal is: Subject to Where, Represents the j-th cluster centroid μ j The update process of |C j | represents cluster C j The number of samples in Represents cluster C j The i-th source domain sample, Represents cluster C j The successive accumulation of all sample feature vectors in ; The goal and constraints of the centroid update are shown in the above formula, that is, to minimize the sum of the distances between the samples in the cluster and the centroid of the cluster, C j is the jth cluster, μ j is the jth centroid, j = 1…k, indicating the traversal of clusters and centroids; Among the constraints, is the jth initial centroid, and ε is a very small constant; In step S45, a distance threshold is set to remove source domain samples that are too far away from the cluster centroid; Calculate the distance from the sample to the centroid: On this basis, source domain samples are screened to obtain the filtered source domain sample set: Where, d ij is the distance from the i-th sample to the j-th centroid; is the i-th sample in the source domain, μ j is the jth centroid; C′ j is the filtered source domain sample set, which contains multiple source domain samples θ is a pre-set distance threshold; In step S46, the category labels of the migrated source domain samples are redistributed according to the target domain category labels corresponding to the cluster centroids: In the formula, the new category label of the i-th source domain sample in the filtered source domain sample set is The target domain category label μ corresponding to the centroid of the filtered source domain sample set j .
Citation Information
Cited By
User portrait label value analysis method and system
CN121093025A