bug 处理

This commit is contained in:
13405411873 2025-04-03 08:46:43 +08:00
parent 18b58c0305
commit ab3c31c03a
6 changed files with 30 additions and 23 deletions

View File

@ -21,7 +21,7 @@ public class PatientScript extends BaseEntity {
//患者姓名
private String patientName;
//患者年龄
private Integer patientAge;
private String patientAge;
//性别
private String patientSex;
//证件信息号

View File

@ -243,10 +243,12 @@ public class PatientScriptServiceImpl implements PatientScriptService {
} else {
System.out.println("文件夹已存在,无需再次创建!");
}
patientScript.setPatientAge("0");
//处理数据处理格式
ShellUtil.execCmd("dos2unix "+dealDataSh);
shUtil(dealDataSh,patientScript);
shMap.put("tr",patientScript.getRepetitionTime());
shMap.put("age",patientScript.getPatientAge());
//创建总脚本
createFile(shMap, shPath,"cpacSh.ftl");

View File

@ -23,6 +23,27 @@ public class ShellUtil {
patientScript.setRepetitionTime(jsonObject.get("tr").toString());
}
if (line.contains("姓名")){
System.out.println(line+"姓名************************************************************");
String[] parts = line.split(":");
if (parts.length > 1) {
String name = parts[1].trim();
if(StringUtils.isEmpty(patientScript.getPatientName())){
patientScript.setPatientName(name);
}
}
}
if (line.contains("年龄")){
System.out.println(line+"年龄************************************************************");
String[] parts = line.split(":");
if (parts.length > 1) {
String age = parts[1].trim();
patientScript.setPatientAge(age);
}else {
patientScript.setPatientAge("0");
}
}
if (line.contains("brain_regions")||line.contains("correlation")){
String resInfo1 = patientScript.getResInfo();
if (StringUtils.isEmpty(resInfo1)){

View File

@ -15,7 +15,7 @@ cd ${matrixPath}
python main.py --sub_id ${subId} --root_dir ${fmriOutPath} --module_dir /data/config/models_9_9 --matrix_path ${matrixPath}
python number_change_script.py
python number_change_script.py --age ${age}
python extract_regions.py
echo "main handle end!"

View File

@ -7,4 +7,5 @@ python dealTest.py --base_dir ${playground} --output_dir ${playground}/BIDS_outp
rm -rf ./${playground}/BIDS_output/config.json
cp ./README ${playground}/BIDS_output/
echo "通过源文件进行二次处理"
docker run --rm -e DOCKER_VERSION_8395080871=27.3.1 -v /data/license.txt:/opt/freesurfer/license.txt:ro -v /data/${playground}/BIDS_output:/data:ro -v /data/${playground}/preprocessed:/out nipreps/fmriprep:23.2.3 /data /out participant --participant-label 001 --fs-no-reconall
docker run --rm -e DOCKER_VERSION_8395080871=27.3.1 -v /data/license.txt:/opt/freesurfer/license.txt:ro -v /data/${playground}/BIDS_output:/data:ro -v /data/${playground}/preprocessed:/out nipreps/fmriprep:23.2.3 /data /out participant --participant-label 001 --fs-no-reconall
python script.py --dicom_folder ${playground}

View File

@ -81,6 +81,9 @@
<!-- 添加或修改测评记录对话框 -->
<el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-form-item label="扫描文件" prop="filePath">
<brain-upload :limit="1" v-model="form.filePath" />
</el-form-item>
<el-form-item label="患者姓名" prop="patientName">
<el-input v-model="form.patientName" placeholder="请输入患者姓名" />
</el-form-item>
@ -120,9 +123,6 @@
<el-form-item label="审核医生" prop="shDoctor">
<el-input v-model="form.shDoctor" placeholder="审核医生" />
</el-form-item>
<el-form-item label="扫描文件" prop="filePath">
<brain-upload :limit="1" v-model="form.filePath" />
</el-form-item>
</el-form>
@ -209,23 +209,6 @@
},
//
rules: {
patientName: [
{
required: true,
message: "患者姓名不能为空",
trigger: "blur",
},
],
scanTime: [
{
required: true,
message: "扫描时间不能为空",
trigger: "blur",
},
],
scanPosition: [
{
required: true,