Add medical order downloader with patient ID template
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
# medical_orders
|
||||
|
||||
批量从住院病历系统(HIS)抓取患者医嘱(长期医嘱 + 临时医嘱),按住院次归档保存。
|
||||
|
||||
## 用法
|
||||
|
||||
1. 复制 `patient_id_template.csv`,把示例行换成真实的住院号(`Patient_ID` 列),另存为例如 `patient_id.csv`(该文件名已在 `.gitignore` 中排除,不会被提交)。
|
||||
2. 安装依赖:
|
||||
|
||||
```
|
||||
pip install -r requirements.txt
|
||||
```
|
||||
|
||||
3. 运行:
|
||||
|
||||
```
|
||||
python download_orders.py --template patient_id.csv --output-dir orders_output
|
||||
```
|
||||
|
||||
## 输出
|
||||
|
||||
写入 `--output-dir`(默认 `orders_output/`,已在 `.gitignore` 中排除):
|
||||
|
||||
- `<住院号>.json`:该患者每次住院的长期/临时医嘱原始行数据
|
||||
- `orders_summary.csv`:所有患者、所有住院次的医嘱汇总表
|
||||
|
||||
## 隐私说明
|
||||
|
||||
抓取结果包含患者姓名、住院号等真实隐私信息(PHI),**任何情况下都不要提交到 Git 仓库**。仓库里只保留代码和空模板;真实的患者名单文件和下载结果目录已通过 `.gitignore` 排除。
|
||||
Reference in New Issue
Block a user