人工交互分析gamma模块分析峰数据时,页面获取字段直接赋值到对应峰信息

This commit is contained in:
qiaoqinzheng 2023-12-01 11:35:06 +08:00
parent 312aebbc99
commit cece7bb5e6

View File

@ -1461,16 +1461,8 @@ public class GammaServiceImpl extends AbstractLogOrReport implements IGammaServi
for (int j = 0; j < tablePeaksList.size(); j++) {
TablePeaks nPeak = tablePeaksList.get(j);
PeakInfo peak = phd.getVPeak().get(Integer.valueOf(nPeak.getLab()) - 1);
if (!NumberFormatUtil.numberFormat(String.valueOf(peak.energy)).equals(nPeak.getEnergy()) ) {
peak.energy = Double.parseDouble(nPeak.getEnergy());
}
if (!NumberFormatUtil.numberFormat(String.valueOf(peak.area)).equals(nPeak.getNetArea())) {
peak.area = Double.parseDouble(nPeak.getNetArea());
}
if (!NumberFormatUtil.numberFormat(String.valueOf(peak.fwhm)).equals(nPeak.getFwhm())) {
peak.fwhm = Double.parseDouble(nPeak.getFwhm());
}
double dE = CalValuesHandler.calDerivaOut(peak.peakCentroid, phd.getUsedEnerPara().getP());
peak.energy = Double.parseDouble(nPeak.getEnergy());
if (peak.energy < vE_Rg.get(0) || peak.energy > vE_Rg.get(1)) {
result.error500("The energy isn't in the analysis range.");
@ -1479,6 +1471,8 @@ public class GammaServiceImpl extends AbstractLogOrReport implements IGammaServi
List<Double> energys = new LinkedList<>();
energys.add(peak.energy);
peak.peakCentroid = CalValuesHandler.energyToChannel(energys, phd.getUsedEnerPara().getP()).counts.get(0);
peak.area = Double.parseDouble(nPeak.getNetArea());
peak.fwhm = Double.parseDouble(nPeak.getFwhm());
peak.stepRatio = Double.valueOf(nPeak.getStep()) / peak.area;
peak.BWWidthChan = Double.valueOf(nPeak.getBwGamma()) / dE;
if (dE > 0) {