ion-CSP 2.1.5__py3-none-any.whl → 2.1.9__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ion_CSP/__init__.py +3 -3
- ion_CSP/convert_SMILES.py +39 -11
- ion_CSP/empirical_estimate.py +288 -84
- ion_CSP/gen_opt.py +68 -22
- ion_CSP/identify_molecules.py +15 -0
- ion_CSP/log_and_time.py +55 -8
- ion_CSP/mlp_opt.py +52 -6
- ion_CSP/read_mlp_density.py +15 -1
- {run → ion_CSP/run}/main_EE.py +11 -13
- ion_CSP/task_manager.py +2 -2
- ion_CSP/upload_download.py +0 -1
- ion_CSP/vasp_processing.py +57 -28
- {ion_csp-2.1.5.dist-info → ion_csp-2.1.9.dist-info}/METADATA +44 -16
- ion_csp-2.1.9.dist-info/RECORD +43 -0
- {ion_csp-2.1.5.dist-info → ion_csp-2.1.9.dist-info}/licenses/LICENSE +1 -1
- {ion_csp-2.1.5.dist-info → ion_csp-2.1.9.dist-info}/top_level.txt +0 -1
- ion_csp-2.1.5.dist-info/RECORD +0 -44
- run/update_changelog.py +0 -68
- {run → ion_CSP/run}/__init__.py +0 -0
- {run → ion_CSP/run}/main_CSP.py +0 -0
- {run → ion_CSP/run}/run_convert_SMILES.py +0 -0
- {run → ion_CSP/run}/run_empirical_estimate.py +0 -0
- {run → ion_CSP/run}/run_gen_opt.py +0 -0
- {run → ion_CSP/run}/run_read_mlp_density.py +0 -0
- {run → ion_CSP/run}/run_upload_download.py +0 -0
- {run → ion_CSP/run}/run_vasp_processing.py +0 -0
- {ion_csp-2.1.5.dist-info → ion_csp-2.1.9.dist-info}/WHEEL +0 -0
- {ion_csp-2.1.5.dist-info → ion_csp-2.1.9.dist-info}/entry_points.txt +0 -0
ion_CSP/vasp_processing.py
CHANGED
@@ -4,6 +4,7 @@ import json
|
|
4
4
|
import yaml
|
5
5
|
import shutil
|
6
6
|
import logging
|
7
|
+
import importlib.resources
|
7
8
|
from ase.io import ParseError
|
8
9
|
from ase.io.vasp import read_vasp_out
|
9
10
|
from dpdispatcher import Machine, Resources, Task, Submission
|
@@ -13,12 +14,18 @@ from ion_CSP.identify_molecules import identify_molecules, molecules_information
|
|
13
14
|
|
14
15
|
class VaspProcessing:
|
15
16
|
def __init__(self, work_dir: str):
|
17
|
+
"""
|
18
|
+
This directory is used to store all the files related to VASP optimizations.
|
19
|
+
|
20
|
+
:params
|
21
|
+
work_dir: The working directory where VASP optimization files will be stored.
|
22
|
+
"""
|
16
23
|
redirect_dpdisp_logging(os.path.join(work_dir, "dpdispatcher.log"))
|
17
24
|
self.base_dir = work_dir
|
18
25
|
os.chdir(self.base_dir)
|
19
26
|
self.for_vasp_opt_dir = f"{work_dir}/3_for_vasp_opt"
|
20
27
|
self.vasp_optimized_dir = f"{work_dir}/4_vasp_optimized"
|
21
|
-
self.param_dir =
|
28
|
+
self.param_dir = importlib.resources.files("ion_CSP.param")
|
22
29
|
|
23
30
|
def dpdisp_vasp_optimization_tasks(
|
24
31
|
self,
|
@@ -28,6 +35,10 @@ class VaspProcessing:
|
|
28
35
|
):
|
29
36
|
"""
|
30
37
|
Based on the dpdispatcher module, prepare and submit files for optimization on remote server or local machine.
|
38
|
+
:params
|
39
|
+
machine: The machine configuration file, which can be in JSON or YAML format.
|
40
|
+
resources: The resources configuration file, which can be in JSON or YAML format.
|
41
|
+
nodes: The number of nodes to distribute the optimization tasks across.
|
31
42
|
"""
|
32
43
|
# 调整工作目录,减少错误发生
|
33
44
|
os.chdir(self.for_vasp_opt_dir)
|
@@ -79,7 +90,7 @@ class VaspProcessing:
|
|
79
90
|
task_dir = os.path.join(self.for_vasp_opt_dir, f"{parent}pop{pop}")
|
80
91
|
os.makedirs(task_dir, exist_ok=True)
|
81
92
|
for file in forward_files:
|
82
|
-
shutil.copyfile(
|
93
|
+
shutil.copyfile(self.param_dir.joinpath(file), f"{task_dir}/{file}")
|
83
94
|
for job_i in node_jobs[pop]:
|
84
95
|
# 将分配好的POSCAR文件添加到对应的上传文件中
|
85
96
|
forward_files.append(mlp_contcar_files[job_i])
|
@@ -146,7 +157,11 @@ class VaspProcessing:
|
|
146
157
|
nodes: int = 1,
|
147
158
|
):
|
148
159
|
"""
|
149
|
-
Based on the dpdispatcher module, prepare and submit files for
|
160
|
+
Based on the dpdispatcher module, prepare and submit files for VASP relaxation on remote server or local machine.
|
161
|
+
:params
|
162
|
+
machine: The machine configuration file, which can be in JSON or YAML format.
|
163
|
+
resources: The resources configuration file, which can be in JSON or YAML format.
|
164
|
+
nodes: The number of nodes to distribute the optimization tasks across.
|
150
165
|
"""
|
151
166
|
# 调整工作目录,减少错误发生
|
152
167
|
os.chdir(self.vasp_optimized_dir)
|
@@ -199,19 +214,20 @@ class VaspProcessing:
|
|
199
214
|
task_dir = os.path.join(self.vasp_optimized_dir, f"{parent}pop{pop}")
|
200
215
|
os.makedirs(task_dir, exist_ok=True)
|
201
216
|
for file in forward_files:
|
202
|
-
shutil.copyfile(
|
217
|
+
shutil.copyfile(self.param_dir.joinpath(file), f"{task_dir}/{file}")
|
203
218
|
for job_i in node_jobs[pop]:
|
204
219
|
# 将分配好的POSCAR文件添加到对应的上传文件中
|
205
220
|
vasp_dir = vasp_optimized_folders[job_i]
|
206
221
|
fine_optimized_file = f"{vasp_dir}/fine/CONTCAR"
|
207
|
-
|
208
|
-
|
209
|
-
os.
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
222
|
+
if os.path.exists(fine_optimized_file):
|
223
|
+
forward_files.append(fine_optimized_file)
|
224
|
+
os.makedirs(
|
225
|
+
os.path.dirname(f"{task_dir}/{fine_optimized_file}"), exist_ok=True
|
226
|
+
)
|
227
|
+
shutil.copyfile(
|
228
|
+
f"{self.vasp_optimized_dir}/{fine_optimized_file}",
|
229
|
+
f"{task_dir}/{fine_optimized_file}",
|
230
|
+
)
|
215
231
|
# 每个POSCAR文件在优化后都取回对应的CONTCAR和OUTCAR输出文件
|
216
232
|
backward_files.append(f"{vasp_dir}/*")
|
217
233
|
backward_files.append(f"{vasp_dir}/fine/*")
|
@@ -311,7 +327,7 @@ class VaspProcessing:
|
|
311
327
|
task_dir = os.path.join(self.for_vasp_opt_dir, f"{parent}pop{pop}")
|
312
328
|
os.makedirs(task_dir, exist_ok=True)
|
313
329
|
for file in forward_files:
|
314
|
-
shutil.copyfile(
|
330
|
+
shutil.copyfile(self.param_dir.joinpath(file), f"{task_dir}/{file}")
|
315
331
|
for job_i in node_jobs[pop]:
|
316
332
|
# 将分配好的POSCAR文件添加到对应的上传文件中
|
317
333
|
forward_files.append(mlp_contcar_files[job_i])
|
@@ -622,6 +638,11 @@ class VaspProcessing:
|
|
622
638
|
with open(csv_file_path, "r") as csvfile:
|
623
639
|
reader = csv.reader(csvfile)
|
624
640
|
# 跳过表头读取第一行结构序号,即符合结构筛选要求的最大密度结构
|
641
|
+
header = next(reader)
|
642
|
+
if header[0] != "Number":
|
643
|
+
raise KeyError(
|
644
|
+
"The first column of the CSV file is not 'Number', please check the file format."
|
645
|
+
)
|
625
646
|
first_row = next(reader)
|
626
647
|
structure_number = str(first_row[0])
|
627
648
|
# 根据结构序号构建要查找的文件夹路径
|
@@ -632,24 +653,27 @@ class VaspProcessing:
|
|
632
653
|
structure_number
|
633
654
|
):
|
634
655
|
# 查找 CONTCAR 文件
|
635
|
-
final_contcar_path = os.path.join(
|
636
|
-
|
637
|
-
)
|
656
|
+
# final_contcar_path = os.path.join(
|
657
|
+
# vasp_folder_path, "fine", "final", "CONTCAR"
|
658
|
+
# )
|
659
|
+
# print(f"Trying to get the final structure from {vasp_folder_path}")
|
660
|
+
# logging.info(
|
661
|
+
# f"Trying to get the final structure from {vasp_folder_path}"
|
662
|
+
# )
|
663
|
+
# if os.path.exists(final_contcar_path):
|
664
|
+
# # 复制 CONTCAR 文件到 combo_n 文件夹并重命名为 POSCAR
|
665
|
+
# shutil.copy(
|
666
|
+
# final_contcar_path, os.path.join(self.base_dir, "POSCAR")
|
667
|
+
# )
|
668
|
+
# print(f"Renamed CONTCAR to POSCAR in {self.base_dir}, copied from {final_contcar_path}")
|
669
|
+
# logging.info(
|
670
|
+
# f"Renamed CONTCAR to POSCAR in {self.base_dir}, copied from {final_contcar_path}"
|
671
|
+
# )
|
638
672
|
fine_contcar_path = os.path.join(
|
639
673
|
vasp_folder_path, "fine", "CONTCAR"
|
640
674
|
)
|
641
|
-
|
642
|
-
f"
|
643
|
-
)
|
644
|
-
if os.path.exists(final_contcar_path):
|
645
|
-
# 复制 CONTCAR 文件到 combo_n 文件夹并重命名为 POSCAR
|
646
|
-
shutil.copy(
|
647
|
-
final_contcar_path, os.path.join(self.base_dir, "POSCAR")
|
648
|
-
)
|
649
|
-
logging.info(
|
650
|
-
f"Renamed CONTCAR to POSCAR in {self.base_dir}, copied from {final_contcar_path}"
|
651
|
-
)
|
652
|
-
elif os.path.exists(fine_contcar_path):
|
675
|
+
if os.path.exists(fine_contcar_path):
|
676
|
+
print(f"CONTCAR not found in {os.path.join(vasp_folder_path, 'fine', 'final')}")
|
653
677
|
logging.info(
|
654
678
|
f"CONTCAR not found in {os.path.join(vasp_folder_path, 'fine', 'final')}"
|
655
679
|
)
|
@@ -657,10 +681,15 @@ class VaspProcessing:
|
|
657
681
|
shutil.copy(
|
658
682
|
fine_contcar_path, os.path.join(self.base_dir, "POSCAR")
|
659
683
|
)
|
684
|
+
print(f"Renamed CONTCAR to POSCAR in {self.base_dir}, copied from {fine_contcar_path}")
|
660
685
|
logging.info(
|
661
686
|
f"Renamed CONTCAR to POSCAR in {self.base_dir}, copied from {fine_contcar_path}"
|
662
687
|
)
|
663
688
|
else:
|
664
689
|
print(f"Eligible CONTCAR not found in {vasp_folder_path}")
|
690
|
+
logging.info(
|
691
|
+
f"Eligible CONTCAR not found in {vasp_folder_path}"
|
692
|
+
)
|
665
693
|
else:
|
694
|
+
print(f"CSV file not found in {self.base_dir}")
|
666
695
|
logging.info(f"CSV file not found in {self.base_dir}")
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: ion_CSP
|
3
|
-
Version: 2.1.
|
3
|
+
Version: 2.1.9
|
4
4
|
Summary: Crystal Structure Design Software Based on Molecular/Ionic Configuration.
|
5
5
|
Home-page: https://github.com/bagabaga007/ion_CSP
|
6
6
|
Author: Ze Yang
|
@@ -28,13 +28,16 @@ Dynamic: home-page
|
|
28
28
|
Dynamic: license-file
|
29
29
|
Dynamic: requires-python
|
30
30
|
|
31
|
-
#
|
31
|
+
# 基于分子/离子构型的晶体结构设计软件 V2.1
|
32
32
|
|
33
33
|
## 项目概述
|
34
|
+
|
34
35
|
基于分子/离子构型的晶体结构设计软件通过结合经验公式、机器学习势函数微调、第一性原理分步优化和分子/离子识别技术,实现了从分子/离子构型出发的高效晶体结构设计。该软件采用模块化设计,支持全流程自动化材料筛选,在保证预测精度的同时显著提升计算效率。
|
35
36
|
|
36
37
|
## 功能特性
|
38
|
+
|
37
39
|
### 核心功能
|
40
|
+
|
38
41
|
- **双模块工作流**
|
39
42
|
- **EE模块**:基于经验评估的离子组合生成
|
40
43
|
- **CSP模块**:基于离子晶体结构预测的优化筛选
|
@@ -48,13 +51,16 @@ Dynamic: requires-python
|
|
48
51
|
- 软链接解析显示实际路径
|
49
52
|
|
50
53
|
### 技术特性
|
54
|
+
|
51
55
|
- 跨平台支持(Linux/Docker)
|
52
56
|
- 基于Python 3.11+的面向对象架构
|
53
57
|
- 集成psutil进程管理
|
54
58
|
- 结构化日志记录系统
|
55
59
|
|
56
60
|
## 安装指南
|
61
|
+
|
57
62
|
### 环境要求
|
63
|
+
|
58
64
|
| 组件 | 最低版本 |
|
59
65
|
|-------------|----------|
|
60
66
|
| Python | 3.11 |
|
@@ -71,10 +77,13 @@ Dynamic: requires-python
|
|
71
77
|
| rdkit | 2024.03.3|
|
72
78
|
|
73
79
|
### 安装步骤
|
80
|
+
|
74
81
|
```bash
|
75
82
|
pip install ion-csp
|
76
83
|
```
|
84
|
+
|
77
85
|
或
|
86
|
+
|
78
87
|
```bash
|
79
88
|
# 创建虚拟环境
|
80
89
|
python -m venv venv
|
@@ -87,29 +96,39 @@ pip install -e .
|
|
87
96
|
```
|
88
97
|
|
89
98
|
## 快速入门
|
99
|
+
|
90
100
|
### 交互模式
|
101
|
+
|
91
102
|
```bash
|
92
103
|
ion-csp
|
93
104
|
```
|
105
|
+
|
94
106
|
启动交互式命令行界面,支持以下操作:
|
107
|
+
|
95
108
|
- 模块选择
|
96
109
|
- 日志查看
|
97
110
|
- 进程管理
|
98
111
|
|
99
112
|
### 脚本调用
|
113
|
+
|
100
114
|
#### EE模块示例
|
115
|
+
|
101
116
|
```bash
|
102
117
|
./scripts/main_EE.sh examples/example_1
|
103
118
|
```
|
119
|
+
|
104
120
|
从SMILES表格生成离子组合
|
105
121
|
|
106
122
|
#### CSP模块示例
|
123
|
+
|
107
124
|
```bash
|
108
125
|
./scripts/main_CSP.sh examples/example_2
|
109
126
|
```
|
127
|
+
|
110
128
|
从离子组合生成并优化晶体结构
|
111
129
|
|
112
130
|
## 技术架构
|
131
|
+
|
113
132
|
```mermaid
|
114
133
|
graph TD
|
115
134
|
A[用户界面] --> B[任务管理器]
|
@@ -118,34 +137,32 @@ graph TD
|
|
118
137
|
B --> E[日志系统]
|
119
138
|
B --> F[任务调度]
|
120
139
|
C --> G[经验评估引擎]
|
121
|
-
D --> H[
|
140
|
+
D --> H[离子晶体结构预测引擎]
|
122
141
|
E --> I[结构化日志]
|
123
142
|
F --> J[进程终止]
|
124
143
|
```
|
125
144
|
|
126
145
|
## 贡献指南
|
146
|
+
|
127
147
|
1. Fork仓库并创建特性分支
|
128
148
|
2. 编写单元测试覆盖新功能
|
129
149
|
3. 提交Pull Request时注明关联Issue
|
130
150
|
4. 遵循PEP8代码规范
|
131
151
|
|
132
152
|
## 许可证
|
133
|
-
本项目采用MIT许可证,详见LICENSE文件。
|
134
153
|
|
135
|
-
|
136
|
-
- **文档更新**:2025年6月
|
137
|
-
- **最新版本**:v2.1.5
|
138
|
-
- **问题追踪**:https://github.com/bagabaga007/ion_CSP/issues
|
154
|
+
本项目采用MIT许可证,详见LICENSE文件。
|
139
155
|
|
140
156
|
---
|
141
157
|
|
142
|
-
# Crystal Structure Design Software V2.1
|
143
|
-
|
144
158
|
## Project Overview
|
159
|
+
|
145
160
|
This software enables efficient crystal structure design from molecular/ion configurations by integrating empirical formulas, tuned machine learning potentials, stepwise first-principles optimization, and molecular/ion recognition techniques. The modular architecture ensures extensibility and maintainability while maintaining prediction accuracy.
|
146
161
|
|
147
162
|
## Key Features
|
163
|
+
|
148
164
|
### Core Functionalities
|
165
|
+
|
149
166
|
- **Dual-Module Workflow**
|
150
167
|
- **EE Module**: Empirical evaluation-based ion combination generation
|
151
168
|
- **CSP Module**: Ion crystal structure prediction and optimization
|
@@ -159,13 +176,16 @@ This software enables efficient crystal structure design from molecular/ion conf
|
|
159
176
|
- Symlink resolution for actual log paths
|
160
177
|
|
161
178
|
### Technical Specifications
|
179
|
+
|
162
180
|
- Cross-platform support (Linux/Docker)
|
163
181
|
- Object-oriented architecture with Python 3.11+
|
164
182
|
- Integrated process management via psutil
|
165
183
|
- Structured logging system
|
166
184
|
|
167
185
|
## Installation
|
186
|
+
|
168
187
|
### Prerequisites
|
188
|
+
|
169
189
|
| Component | Min Version |
|
170
190
|
|-------------|-------------|
|
171
191
|
| Python | 3.11 |
|
@@ -182,6 +202,7 @@ This software enables efficient crystal structure design from molecular/ion conf
|
|
182
202
|
| rdkit | 2024.03.3|
|
183
203
|
|
184
204
|
### Installation Steps
|
205
|
+
|
185
206
|
```bash
|
186
207
|
# Create virtual environment
|
187
208
|
python -m venv venv
|
@@ -194,29 +215,39 @@ pip install -e .
|
|
194
215
|
```
|
195
216
|
|
196
217
|
## Quick Start
|
218
|
+
|
197
219
|
### Interactive Mode
|
220
|
+
|
198
221
|
```bash
|
199
222
|
ion-csp
|
200
223
|
```
|
224
|
+
|
201
225
|
Launches CLI interface with:
|
226
|
+
|
202
227
|
- Module selection
|
203
228
|
- Log management
|
204
229
|
- Process control
|
205
230
|
|
206
231
|
### Script Execution
|
232
|
+
|
207
233
|
#### EE Module Example
|
234
|
+
|
208
235
|
```bash
|
209
236
|
./scripts/main_EE.sh examples/example_1
|
210
237
|
```
|
238
|
+
|
211
239
|
Generates ion combinations from SMILES tables
|
212
240
|
|
213
241
|
#### CSP Module Example
|
242
|
+
|
214
243
|
```bash
|
215
244
|
./scripts/main_CSP.sh examples/example_2
|
216
245
|
```
|
246
|
+
|
217
247
|
Optimizes crystal structures from ion combinations
|
218
248
|
|
219
249
|
## Technical Architecture
|
250
|
+
|
220
251
|
```mermaid
|
221
252
|
graph TD
|
222
253
|
A[User Interface] --> B[Task Manager]
|
@@ -225,21 +256,18 @@ graph TD
|
|
225
256
|
B --> E[Log System]
|
226
257
|
B --> F[Task Scheduler]
|
227
258
|
C --> G[Empirical Evaluation Engine]
|
228
|
-
D --> H[Crystal Prediction Engine]
|
259
|
+
D --> H[Ionic Crystal Structure Prediction Engine]
|
229
260
|
E --> I[Structured Logs]
|
230
261
|
F --> J[Process Termination]
|
231
262
|
```
|
232
263
|
|
233
264
|
## Contribution Guide
|
265
|
+
|
234
266
|
1. Fork repository and create feature branch
|
235
267
|
2. Write unit tests for new features
|
236
268
|
3. Submit PR with issue reference
|
237
269
|
4. Follow PEP8 coding standards
|
238
270
|
|
239
271
|
## License
|
240
|
-
MIT License, see LICENSE file.
|
241
272
|
|
242
|
-
|
243
|
-
- Documentation last updated: June 2025
|
244
|
-
- Latest version: v2.1.5
|
245
|
-
- Issue tracker: https://github.com/bagabaga007/ion_CSP/issues
|
273
|
+
MIT License, see LICENSE file.
|
@@ -0,0 +1,43 @@
|
|
1
|
+
ion_CSP/__init__.py,sha256=3in4RkuAl_VL3kDHDz_CHQn3zEBtH1Z-H8aFniQbQI8,356
|
2
|
+
ion_CSP/__main__.py,sha256=XlNCx5eMSrL7yld9ddSYXhjXvg2ZYGD_uk9LdqNabvs,74
|
3
|
+
ion_CSP/convert_SMILES.py,sha256=HAexqf6HXZAqRuMww5BKmU68MIO3d7XIaUtPKv_QwMs,15595
|
4
|
+
ion_CSP/empirical_estimate.py,sha256=oqZ-yPbcFCgc0MkOu2PU7JWRNm3fXHm6YRq-bozCZoo,37776
|
5
|
+
ion_CSP/gen_opt.py,sha256=F_gEopuOO-b-tHfS0V4OMeThktY2QvPGWCVRXOCemfk,21605
|
6
|
+
ion_CSP/identify_molecules.py,sha256=GxDWq815Bk_Fq_SR8fe-dbrbEi1YgATVa7UINw3hAu4,5535
|
7
|
+
ion_CSP/log_and_time.py,sha256=Db53LAM2KH_ty6M9_5FF8xDGiULgExh7pcKOvFtS7DQ,11697
|
8
|
+
ion_CSP/mlp_opt.py,sha256=uJaqjNYLzc4dRogNcGIP_Ukta_fMd5YdYVf9cNweOA4,7029
|
9
|
+
ion_CSP/read_mlp_density.py,sha256=KwVgniroT46uFQ7_HROd5Fk9YxJCMip1jnufWvHHEiw,12104
|
10
|
+
ion_CSP/steps_opt_monitor.sh,sha256=1klPjnK0gqkDbvI9PtjdK5qidJ5G0Mo8q1SfrlLW5xM,3330
|
11
|
+
ion_CSP/task_manager.py,sha256=JglPNDKpsv-bjbCm42D4k6GegDkSylX4oDWAdFa-oSU,16569
|
12
|
+
ion_CSP/upload_download.py,sha256=HXxVQMUydEoHe2vV89wR7De4Ut1lEte6pmp8Q82decI,23800
|
13
|
+
ion_CSP/vasp_processing.py,sha256=YhZxEg03n2lwDtoYzpXdUn329QzfOvp4XXm-qTIIIMA,33337
|
14
|
+
ion_CSP/model/model.pt,sha256=5D9HTP5b7jUOv3kHltT71ORzhgt5p96awjbqC4oZVjQ,24649402
|
15
|
+
ion_CSP/model/options/README.md,sha256=ifoeNXF2CfwqUjt3Xmh5qUl-e4hfP4eMV4EkqV7GU30,182
|
16
|
+
ion_CSP/model/options/model.ckpt-4000000.pt,sha256=5D9HTP5b7jUOv3kHltT71ORzhgt5p96awjbqC4oZVjQ,24649402
|
17
|
+
ion_CSP/param/INCAR_0,sha256=qh0cOez9-Lv0wVyf6bCrQ92kWiioOsx-tXthcx2GXtE,295
|
18
|
+
ion_CSP/param/INCAR_1,sha256=GhWmKUcG01XYISIBOoPRSEEtTgbLeZd7-VeZE5WvXnY,351
|
19
|
+
ion_CSP/param/INCAR_2,sha256=951-1SxWO3pZjXmTWcOeDAnaSpUuepyn2FzOXegwRIU,319
|
20
|
+
ion_CSP/param/INCAR_3,sha256=zX6W-oX2xTYc8OEkbfzJiyapI2-uBrMpAJcyyypRJ1E,319
|
21
|
+
ion_CSP/param/POTCAR_C,sha256=BygEoI0xTgy87Xvqko948Rfj5Nw-qAkwhfd5CvJQ5yA,209530
|
22
|
+
ion_CSP/param/POTCAR_H,sha256=ypnE6_RSPVdygq79elXWiZ7gIj6rGVP2VeRXbzY6c74,142686
|
23
|
+
ion_CSP/param/POTCAR_N,sha256=n9-vHqk9sJ6A3C3e1yTw9r9SZKDJc1mArgcfdJ0APA4,213434
|
24
|
+
ion_CSP/param/POTCAR_O,sha256=S5LYsbk2ZWoDj6hLxRucM48wNHgf7BQcCylgwGdL4hA,222698
|
25
|
+
ion_CSP/param/g16_sub.sh,sha256=WOxXhBiPjpZ8eJwdLdLtCfVsWPWh0USxrBbX9u3cunk,519
|
26
|
+
ion_CSP/param/sub_final.sh,sha256=jQSEgNThM8UJT4Vd6AzBFeccn-xoqG-fpSTiXmwzZhM,3222
|
27
|
+
ion_CSP/param/sub_ori.sh,sha256=JBERlc-VOVCNaKGwiJR8oq7Nyf0KV4JpHEVT5sE5s8E,2497
|
28
|
+
ion_CSP/param/sub_supple.sh,sha256=23cam7WyW7-80J8O-Bs45qYkabk3mxZDgiHZvf48KBM,1887
|
29
|
+
ion_CSP/run/__init__.py,sha256=_9EAXp4cv41ARbxahCkihwqY4F00Y18tBeTauWeD9mw,186
|
30
|
+
ion_CSP/run/main_CSP.py,sha256=UaYHlh7BSxar4uGppPi-V0cFDpB14212Oy6gta59LfA,5898
|
31
|
+
ion_CSP/run/main_EE.py,sha256=8TFlJx7QhJKGc4qZ2O0ESRYrlySp3r1WjeGLkUBeL5k,6217
|
32
|
+
ion_CSP/run/run_convert_SMILES.py,sha256=85a8-UXPxPo3Yw_iYED_QF47yNTvYRnJHm3PC1d-d_Q,2056
|
33
|
+
ion_CSP/run/run_empirical_estimate.py,sha256=U_yvQ5gMiBkDEabHXLJSAEm0EzGHhSKs6xmWoEC_gjc,2831
|
34
|
+
ion_CSP/run/run_gen_opt.py,sha256=_Zcsu0FkuZTfiGKSWNaK17LiyQ3qrP30F66UN5QemCo,2727
|
35
|
+
ion_CSP/run/run_read_mlp_density.py,sha256=aSJjWS1jH-D7qzx7RnpMPSTH7KEZp2b35dg1b2OQSCM,1864
|
36
|
+
ion_CSP/run/run_upload_download.py,sha256=wuTAdy4bgdduD7TJtgHwo_fTpHKlkAwmgRknClDLYDo,2436
|
37
|
+
ion_CSP/run/run_vasp_processing.py,sha256=hziE4cZwmIWvVaZtwHn9Dl35apYSLlMvSVIbCyd5mFg,1612
|
38
|
+
ion_csp-2.1.9.dist-info/licenses/LICENSE,sha256=yeL9PshY_rGAt3GKqn8U7NafHifpmZipb-Owu0DDrHo,1070
|
39
|
+
ion_csp-2.1.9.dist-info/METADATA,sha256=OM9yIEVI-_77HaYxgA4qIfed2BRTs34mNgJbfLHYyFg,6314
|
40
|
+
ion_csp-2.1.9.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
41
|
+
ion_csp-2.1.9.dist-info/entry_points.txt,sha256=NexQJDs9f69kJA2DgoU6tsA3V8a66nadJRem1U_c_6g,54
|
42
|
+
ion_csp-2.1.9.dist-info/top_level.txt,sha256=aYZa43dDebjLpWPN6bDIlBb6BVwA8gk4ajEjDDK9b9I,8
|
43
|
+
ion_csp-2.1.9.dist-info/RECORD,,
|
ion_csp-2.1.5.dist-info/RECORD
DELETED
@@ -1,44 +0,0 @@
|
|
1
|
-
ion_CSP/__init__.py,sha256=L5DyCHC4xoiu_KnOW1rVheNbNVooNtuyr75m1z6YbkU,374
|
2
|
-
ion_CSP/__main__.py,sha256=XlNCx5eMSrL7yld9ddSYXhjXvg2ZYGD_uk9LdqNabvs,74
|
3
|
-
ion_CSP/convert_SMILES.py,sha256=4fndMcuIEypYtkXWBoS7W7uEXkZXVLeMDshdXEIk5kY,13864
|
4
|
-
ion_CSP/empirical_estimate.py,sha256=_U5VRWSIAiJGcxnP3mnCHn8zKzviFEQhQwN7TjPTnCU,29089
|
5
|
-
ion_CSP/gen_opt.py,sha256=e_B0OIRb7nnrNGKuM8PttuRdwOkOH1YtZwBkP7GIZv8,19660
|
6
|
-
ion_CSP/identify_molecules.py,sha256=hFKXS0Jjd7LyMsYGc9RmnoRPu1ibXF9fYO_9lR3wTfo,4634
|
7
|
-
ion_CSP/log_and_time.py,sha256=-RCycW1VB7sa3bjQZiF7c8i73iam8S41qgJxlHRqJaw,9406
|
8
|
-
ion_CSP/mlp_opt.py,sha256=ox4Qxg4D6WzrB8dxVnUWmAngnOA_wdcInP5UhBWsH4c,5535
|
9
|
-
ion_CSP/read_mlp_density.py,sha256=3N7kgM2RCe1gbP8QxpgtwYRaj77w4niNglWA5VDoQsk,11209
|
10
|
-
ion_CSP/steps_opt_monitor.sh,sha256=1klPjnK0gqkDbvI9PtjdK5qidJ5G0Mo8q1SfrlLW5xM,3330
|
11
|
-
ion_CSP/task_manager.py,sha256=pz9xPkCFBpKmeZFgylfUV5iSs4tgbasTZkX0m3lIlWE,16568
|
12
|
-
ion_CSP/upload_download.py,sha256=Hiz5jKOy9x26hJJdcpt-owQdVUbzzGuGOelro6JozY8,23801
|
13
|
-
ion_CSP/vasp_processing.py,sha256=TshMNs7fA0zABvk4sKlVjofJFwGH9DVYcCGbcUpoH1s,31542
|
14
|
-
ion_CSP/model/model.pt,sha256=5D9HTP5b7jUOv3kHltT71ORzhgt5p96awjbqC4oZVjQ,24649402
|
15
|
-
ion_CSP/model/options/README.md,sha256=ifoeNXF2CfwqUjt3Xmh5qUl-e4hfP4eMV4EkqV7GU30,182
|
16
|
-
ion_CSP/model/options/model.ckpt-4000000.pt,sha256=5D9HTP5b7jUOv3kHltT71ORzhgt5p96awjbqC4oZVjQ,24649402
|
17
|
-
ion_CSP/param/INCAR_0,sha256=qh0cOez9-Lv0wVyf6bCrQ92kWiioOsx-tXthcx2GXtE,295
|
18
|
-
ion_CSP/param/INCAR_1,sha256=GhWmKUcG01XYISIBOoPRSEEtTgbLeZd7-VeZE5WvXnY,351
|
19
|
-
ion_CSP/param/INCAR_2,sha256=951-1SxWO3pZjXmTWcOeDAnaSpUuepyn2FzOXegwRIU,319
|
20
|
-
ion_CSP/param/INCAR_3,sha256=zX6W-oX2xTYc8OEkbfzJiyapI2-uBrMpAJcyyypRJ1E,319
|
21
|
-
ion_CSP/param/POTCAR_C,sha256=BygEoI0xTgy87Xvqko948Rfj5Nw-qAkwhfd5CvJQ5yA,209530
|
22
|
-
ion_CSP/param/POTCAR_H,sha256=ypnE6_RSPVdygq79elXWiZ7gIj6rGVP2VeRXbzY6c74,142686
|
23
|
-
ion_CSP/param/POTCAR_N,sha256=n9-vHqk9sJ6A3C3e1yTw9r9SZKDJc1mArgcfdJ0APA4,213434
|
24
|
-
ion_CSP/param/POTCAR_O,sha256=S5LYsbk2ZWoDj6hLxRucM48wNHgf7BQcCylgwGdL4hA,222698
|
25
|
-
ion_CSP/param/g16_sub.sh,sha256=WOxXhBiPjpZ8eJwdLdLtCfVsWPWh0USxrBbX9u3cunk,519
|
26
|
-
ion_CSP/param/sub_final.sh,sha256=jQSEgNThM8UJT4Vd6AzBFeccn-xoqG-fpSTiXmwzZhM,3222
|
27
|
-
ion_CSP/param/sub_ori.sh,sha256=JBERlc-VOVCNaKGwiJR8oq7Nyf0KV4JpHEVT5sE5s8E,2497
|
28
|
-
ion_CSP/param/sub_supple.sh,sha256=23cam7WyW7-80J8O-Bs45qYkabk3mxZDgiHZvf48KBM,1887
|
29
|
-
ion_csp-2.1.5.dist-info/licenses/LICENSE,sha256=2J6A8GT2iIf2LhuWO1_0ilgx7ijzzpQ2BXU7rHKe8Cc,1068
|
30
|
-
run/__init__.py,sha256=_9EAXp4cv41ARbxahCkihwqY4F00Y18tBeTauWeD9mw,186
|
31
|
-
run/main_CSP.py,sha256=UaYHlh7BSxar4uGppPi-V0cFDpB14212Oy6gta59LfA,5898
|
32
|
-
run/main_EE.py,sha256=4L0VbbgUaYaDJM-6EjffphxMoWAHaZchEaSCVJxsdls,6345
|
33
|
-
run/run_convert_SMILES.py,sha256=85a8-UXPxPo3Yw_iYED_QF47yNTvYRnJHm3PC1d-d_Q,2056
|
34
|
-
run/run_empirical_estimate.py,sha256=U_yvQ5gMiBkDEabHXLJSAEm0EzGHhSKs6xmWoEC_gjc,2831
|
35
|
-
run/run_gen_opt.py,sha256=_Zcsu0FkuZTfiGKSWNaK17LiyQ3qrP30F66UN5QemCo,2727
|
36
|
-
run/run_read_mlp_density.py,sha256=aSJjWS1jH-D7qzx7RnpMPSTH7KEZp2b35dg1b2OQSCM,1864
|
37
|
-
run/run_upload_download.py,sha256=wuTAdy4bgdduD7TJtgHwo_fTpHKlkAwmgRknClDLYDo,2436
|
38
|
-
run/run_vasp_processing.py,sha256=hziE4cZwmIWvVaZtwHn9Dl35apYSLlMvSVIbCyd5mFg,1612
|
39
|
-
run/update_changelog.py,sha256=ShnVG7v3qSQAzWUA90bFbWGwI3lwfbA_ugov6avS3jU,2121
|
40
|
-
ion_csp-2.1.5.dist-info/METADATA,sha256=YmomKcyGXzBZ-e9GWVpM2txQjPBlF6sAORk3sZ7Fw-0,6554
|
41
|
-
ion_csp-2.1.5.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
42
|
-
ion_csp-2.1.5.dist-info/entry_points.txt,sha256=NexQJDs9f69kJA2DgoU6tsA3V8a66nadJRem1U_c_6g,54
|
43
|
-
ion_csp-2.1.5.dist-info/top_level.txt,sha256=Vp0RHefYscYU7uQ4Fu6bOKhC_ASrdGOzZxYfN5r0f2M,12
|
44
|
-
ion_csp-2.1.5.dist-info/RECORD,,
|
run/update_changelog.py
DELETED
@@ -1,68 +0,0 @@
|
|
1
|
-
import subprocess
|
2
|
-
|
3
|
-
|
4
|
-
def get_commit_details():
|
5
|
-
# 获取提交信息,包括哈希、日期和消息
|
6
|
-
result = subprocess.run(
|
7
|
-
["git", "log", "--pretty=format:%h %ad %s", "--date=short"],
|
8
|
-
capture_output=True,
|
9
|
-
text=True,
|
10
|
-
)
|
11
|
-
return result.stdout.splitlines()
|
12
|
-
|
13
|
-
|
14
|
-
def get_commit_tags():
|
15
|
-
# 获取每个提交的标签信息
|
16
|
-
tags = {}
|
17
|
-
commits = get_commit_details()
|
18
|
-
for commit in commits:
|
19
|
-
hash_value = commit.split(" ")[0]
|
20
|
-
result = subprocess.run(
|
21
|
-
["git", "tag", "--points-at", hash_value], capture_output=True, text=True
|
22
|
-
)
|
23
|
-
tag_list = result.stdout.strip().splitlines()
|
24
|
-
tags[hash_value] = tag_list
|
25
|
-
return tags
|
26
|
-
|
27
|
-
|
28
|
-
def generate_changelog(commit_details, tags):
|
29
|
-
changelog_path = "CHANGELOG.md"
|
30
|
-
|
31
|
-
# 生成变更日志内容
|
32
|
-
new_changelog_content = []
|
33
|
-
|
34
|
-
# 添加标题
|
35
|
-
new_changelog_content.append("# Changelog\n\n")
|
36
|
-
|
37
|
-
# 添加每个提交的详细信息
|
38
|
-
for detail in commit_details:
|
39
|
-
hash_value, date, *message = detail.split(" ")
|
40
|
-
message = " ".join(message) # 重新组合提交信息
|
41
|
-
|
42
|
-
# 检查是否有标签
|
43
|
-
if tags.get(hash_value):
|
44
|
-
# 添加标签信息
|
45
|
-
for tag in tags[hash_value]:
|
46
|
-
new_changelog_content.append(f"## {tag}\n")
|
47
|
-
|
48
|
-
# 添加提交信息
|
49
|
-
new_changelog_content.append(f"### {hash_value} ({date})\n")
|
50
|
-
new_changelog_content.append(f"{message}\n\n")
|
51
|
-
else:
|
52
|
-
# 如果没有标签,直接添加提交信息
|
53
|
-
new_changelog_content.append(f"### {hash_value} ({date})\n")
|
54
|
-
new_changelog_content.append(f"{message}\n\n")
|
55
|
-
|
56
|
-
# 写入 CHANGELOG.md
|
57
|
-
with open(changelog_path, "w") as file:
|
58
|
-
file.writelines(new_changelog_content)
|
59
|
-
|
60
|
-
|
61
|
-
if __name__ == "__main__":
|
62
|
-
commit_details = get_commit_details()
|
63
|
-
tags = get_commit_tags() # 获取每个提交的标签信息
|
64
|
-
if commit_details:
|
65
|
-
generate_changelog(commit_details, tags)
|
66
|
-
print("CHANGELOG.md has been updated.")
|
67
|
-
else:
|
68
|
-
print("No new commits found.")
|
{run → ion_CSP/run}/__init__.py
RENAMED
File without changes
|
{run → ion_CSP/run}/main_CSP.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|