SAMBA-ilum 1.1.0.116__tar.gz → 1.1.0.117__tar.gz
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.
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/PKG-INFO +1 -1
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/SAMBA_ilum.egg-info/PKG-INFO +1 -1
- samba_ilum-1.1.0.117/SAMBA_ilum.egg-info/SOURCES.txt +40 -0
- samba_ilum-1.1.0.117/SAMBA_ilum.egg-info/entry_points.txt +2 -0
- samba_ilum-1.1.0.117/samba_ilum/__main__.py +317 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/setup.py +9 -4
- samba_ilum-1.1.0.116/SAMBA_ilum.egg-info/SOURCES.txt +0 -66
- samba_ilum-1.1.0.116/SAMBA_ilum.egg-info/entry_points.txt +0 -2
- samba_ilum-1.1.0.116/samba_ilum/__main__.py +0 -313
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/Hubbard_U_values.txt +0 -13
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_a-scan +0 -21
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_bader +0 -26
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_bader.SO +0 -27
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_bands +0 -24
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_bands.SO +0 -25
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_dos +0 -25
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_dos.SO +0 -26
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_relax +0 -26
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_scf +0 -25
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_scf.SO +0 -26
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_xy-scan +0 -23
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_xyz-scan +0 -23
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/INCAR_z-scan +0 -23
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/SAMBA_HeteroStructure.input +0 -62
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/SAMBA_WorkFlow.input +0 -82
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.bands +0 -95
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.chgcar +0 -66
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.dos +0 -99
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.location +0 -208
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.locpot +0 -32
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.orbitals +0 -140
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.spin +0 -167
- samba_ilum-1.1.0.116/samba_ilum/src/INPUTS/vdw_kernel.bindat +0 -0
- samba_ilum-1.1.0.116/samba_ilum/src/bader +0 -0
- samba_ilum-1.1.0.116/samba_ilum/src/chgsum.pl +0 -97
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/LICENSE.txt +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/README.md +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/SAMBA_ilum.egg-info/dependency_links.txt +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/SAMBA_ilum.egg-info/requires.txt +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/SAMBA_ilum.egg-info/top_level.txt +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/__init__.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/BZ_2D.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/HeteroStructure_Generator.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/_info_pseudo.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/a-scan.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/a-scan_analysis.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/bader_poscar.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/bader_update.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/cell_check.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/charge_transfer.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/contcar_update.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/data-base_json.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/data-base_union.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/energy_scan.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/hubbard_correction.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/job.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/kpoints.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/lattice_plot3d.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/make_files.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/output.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/poscar_fix_direct_coord.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/potcar.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/vdW_DF.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/xy-scan.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/xy-scan_analysis.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/xyz-scan.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/xyz-scan_analysis.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/z-scan.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/samba_ilum/src/z-scan_analysis.py +0 -0
- {samba_ilum-1.1.0.116 → samba_ilum-1.1.0.117}/setup.cfg +0 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
LICENSE.txt
|
|
2
|
+
README.md
|
|
3
|
+
setup.cfg
|
|
4
|
+
setup.py
|
|
5
|
+
SAMBA_ilum.egg-info/PKG-INFO
|
|
6
|
+
SAMBA_ilum.egg-info/SOURCES.txt
|
|
7
|
+
SAMBA_ilum.egg-info/dependency_links.txt
|
|
8
|
+
SAMBA_ilum.egg-info/entry_points.txt
|
|
9
|
+
SAMBA_ilum.egg-info/requires.txt
|
|
10
|
+
SAMBA_ilum.egg-info/top_level.txt
|
|
11
|
+
samba_ilum/__init__.py
|
|
12
|
+
samba_ilum/__main__.py
|
|
13
|
+
samba_ilum/src/BZ_2D.py
|
|
14
|
+
samba_ilum/src/HeteroStructure_Generator.py
|
|
15
|
+
samba_ilum/src/_info_pseudo.py
|
|
16
|
+
samba_ilum/src/a-scan.py
|
|
17
|
+
samba_ilum/src/a-scan_analysis.py
|
|
18
|
+
samba_ilum/src/bader_poscar.py
|
|
19
|
+
samba_ilum/src/bader_update.py
|
|
20
|
+
samba_ilum/src/cell_check.py
|
|
21
|
+
samba_ilum/src/charge_transfer.py
|
|
22
|
+
samba_ilum/src/contcar_update.py
|
|
23
|
+
samba_ilum/src/data-base_json.py
|
|
24
|
+
samba_ilum/src/data-base_union.py
|
|
25
|
+
samba_ilum/src/energy_scan.py
|
|
26
|
+
samba_ilum/src/hubbard_correction.py
|
|
27
|
+
samba_ilum/src/job.py
|
|
28
|
+
samba_ilum/src/kpoints.py
|
|
29
|
+
samba_ilum/src/lattice_plot3d.py
|
|
30
|
+
samba_ilum/src/make_files.py
|
|
31
|
+
samba_ilum/src/output.py
|
|
32
|
+
samba_ilum/src/poscar_fix_direct_coord.py
|
|
33
|
+
samba_ilum/src/potcar.py
|
|
34
|
+
samba_ilum/src/vdW_DF.py
|
|
35
|
+
samba_ilum/src/xy-scan.py
|
|
36
|
+
samba_ilum/src/xy-scan_analysis.py
|
|
37
|
+
samba_ilum/src/xyz-scan.py
|
|
38
|
+
samba_ilum/src/xyz-scan_analysis.py
|
|
39
|
+
samba_ilum/src/z-scan.py
|
|
40
|
+
samba_ilum/src/z-scan_analysis.py
|
|
@@ -0,0 +1,317 @@
|
|
|
1
|
+
# SAMBA_ilum Copyright (C) 2025 - Closed source
|
|
2
|
+
|
|
3
|
+
def main():
|
|
4
|
+
import numpy as np
|
|
5
|
+
import subprocess
|
|
6
|
+
import itertools
|
|
7
|
+
import shutil
|
|
8
|
+
import time
|
|
9
|
+
import sys
|
|
10
|
+
import os
|
|
11
|
+
|
|
12
|
+
#----------------
|
|
13
|
+
dir_codes = 'src'
|
|
14
|
+
dir_files = os.getcwd()
|
|
15
|
+
os.chdir(os.path.dirname(os.path.realpath(__file__)))
|
|
16
|
+
dir_samba = os.path.dirname(os.path.realpath(__file__))
|
|
17
|
+
print(f'{dir_samba}')
|
|
18
|
+
#--------------------
|
|
19
|
+
|
|
20
|
+
version = '1.1.0.117'
|
|
21
|
+
|
|
22
|
+
print(" ")
|
|
23
|
+
print("=============================================================")
|
|
24
|
+
print(f'SAMBA_ilum v{version} Copyright (C) 2025 --------------------')
|
|
25
|
+
print("Closed source: Adalberto Fazzio's research group (Ilum|CNPEM)")
|
|
26
|
+
print("Author: Augusto de Lelis Araujo -----------------------------")
|
|
27
|
+
print("=============================================================")
|
|
28
|
+
print(" ")
|
|
29
|
+
print(" _____ ___ __ _______ ___ _ __ ")
|
|
30
|
+
print(" / ___// | / |/ / __ )/ | (_) /_ ______ ___ ")
|
|
31
|
+
print(""" \__ \/ /| | / /|_/ / __ / /| | / / / / / / __ `___\ """)
|
|
32
|
+
print(" ___/ / ___ |/ / / / /_/ / ___ | / / / /_/ / / / / / /")
|
|
33
|
+
print("/____/_/ |_/_/ /_/_____/_/ |_| /_/_/\__,_/_/ /_/ /_/ ")
|
|
34
|
+
print(f'Simulation and Automated Methods for Bilayer Analysis v{version}')
|
|
35
|
+
print(" ")
|
|
36
|
+
|
|
37
|
+
#------------------------------------------------
|
|
38
|
+
# Checking for updates for SAMBA ----------------
|
|
39
|
+
#------------------------------------------------
|
|
40
|
+
try:
|
|
41
|
+
url = f"https://pypi.org/pypi/{'samba_ilum'}/json"
|
|
42
|
+
response = requests.get(url)
|
|
43
|
+
dados = response.json()
|
|
44
|
+
current_version = dados['info']['version']; current_version = str(current_version)
|
|
45
|
+
if (current_version != version):
|
|
46
|
+
print(" ")
|
|
47
|
+
print("--------------------------------------------------------------")
|
|
48
|
+
print(" !!!!! Your SAMBA version is out of date !!!!! ")
|
|
49
|
+
print("--------------------------------------------------------------")
|
|
50
|
+
print(" To update, close the SAMBA and enter into the terminal: ")
|
|
51
|
+
print(" pip install --upgrade samba ")
|
|
52
|
+
print("--------------------------------------------------------------")
|
|
53
|
+
print(" ")
|
|
54
|
+
print(" ")
|
|
55
|
+
...
|
|
56
|
+
except Exception as e:
|
|
57
|
+
print("--------------------------------------------------------------")
|
|
58
|
+
print(" !!!! Unable to verify the current version of SAMBA !!!! ")
|
|
59
|
+
print("--------------------------------------------------------------")
|
|
60
|
+
print(" ")
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
# ------------------------------------------------------------------------------
|
|
64
|
+
# Checking if the "run.input" file exists --------------------------------------
|
|
65
|
+
# ------------------------------------------------------------------------------
|
|
66
|
+
run_input = 'not'
|
|
67
|
+
#----------------
|
|
68
|
+
if os.path.isfile(dir_files + '/run.input'): run_input = 'yes'
|
|
69
|
+
else: run_input = 'not'
|
|
70
|
+
# ----------------------
|
|
71
|
+
if (run_input == 'yes'):
|
|
72
|
+
run = open(dir_files + '/run.input', "r")
|
|
73
|
+
VTemp = run.readline().split()
|
|
74
|
+
if (len(VTemp) == 3): tarefa = int(VTemp[2])
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
if(run_input == 'not'):
|
|
78
|
+
print("######################################################################")
|
|
79
|
+
print("# What do you want to run? ===========================================")
|
|
80
|
+
print("# ====================================================================")
|
|
81
|
+
print("# [0] Generate SAMBA execution inputs ")
|
|
82
|
+
print("# --------------------------------------------------------------------")
|
|
83
|
+
print("# [1] Heterostructure Generator ")
|
|
84
|
+
print("# [2] WorkFlow: High Throughput DFT (inputs + job) ")
|
|
85
|
+
print("# --------------------------------------------------------------------")
|
|
86
|
+
print("# [3] Customize internal WorkFlow inputs (INPUTS folder) ")
|
|
87
|
+
print("######################################################################")
|
|
88
|
+
print("A tutorial on how to use the SAMBA is available on GitHub at the link:")
|
|
89
|
+
print("https://github.com/Augusto-de-Lelis-Araujo/SAMBA/blob/main/README.md ")
|
|
90
|
+
print("######################################################################")
|
|
91
|
+
tarefa = input(" "); tarefa = int(tarefa)
|
|
92
|
+
print(" ")
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
if (tarefa == 0):
|
|
96
|
+
shutil.copyfile(dir_codes + '/INPUTS/SAMBA_WorkFlow.input', dir_files + '/SAMBA_WorkFlow.input')
|
|
97
|
+
shutil.copyfile(dir_codes + '/INPUTS/SAMBA_HeteroStructure.input', dir_files + '/SAMBA_HeteroStructure.input')
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
if (tarefa == 1):
|
|
101
|
+
#--------------------------------------------------------------------------------------------------
|
|
102
|
+
# Checking if the "SAMBA_HeteroStructure.input" file exists, if it does not exist it is created ---
|
|
103
|
+
#--------------------------------------------------------------------------------------------------
|
|
104
|
+
if os.path.isfile(dir_files + '/SAMBA_HeteroStructure.input'):
|
|
105
|
+
0 == 0
|
|
106
|
+
else:
|
|
107
|
+
shutil.copyfile(dir_codes + '/SAMBA_HeteroStructure.input', dir_files + '/SAMBA_HeteroStructure.input')
|
|
108
|
+
#------------------------------------------------------------------------------------------------------
|
|
109
|
+
print(" ")
|
|
110
|
+
print("==============================================================")
|
|
111
|
+
print("Generated SAMBA_HeteroStructure.input file !!! ===============")
|
|
112
|
+
print("--------------------------------------------------------------")
|
|
113
|
+
print("Configure the SAMBA_HeteroStructure.input file and run the ---")
|
|
114
|
+
print(" code again ---")
|
|
115
|
+
print("==============================================================")
|
|
116
|
+
print(" ")
|
|
117
|
+
#--------------------------------------------------------
|
|
118
|
+
confirmacao = input (" "); confirmacao = str(confirmacao)
|
|
119
|
+
sys.exit()
|
|
120
|
+
#---------
|
|
121
|
+
|
|
122
|
+
#------------------------------------------------------------
|
|
123
|
+
exec(open(dir_files + '/SAMBA_HeteroStructure.input').read())
|
|
124
|
+
#------------------------------------------------------------
|
|
125
|
+
separacao1 = separation_1
|
|
126
|
+
separacao2 = separation_2
|
|
127
|
+
#------------------------
|
|
128
|
+
if (loop_ht == 0):
|
|
129
|
+
Lattice1 = Lattice1.replace(".vasp","") + ".vasp"
|
|
130
|
+
Lattice2 = Lattice2.replace(".vasp","") + ".vasp"
|
|
131
|
+
Lattice3 = Lattice3.replace(".vasp","") + ".vasp"
|
|
132
|
+
#---------------------------------------------------
|
|
133
|
+
|
|
134
|
+
#=============================================================
|
|
135
|
+
# Fixing the coordinates of POSCAR files in direct form ======
|
|
136
|
+
#=============================================================
|
|
137
|
+
dir_files_in = dir_poscar
|
|
138
|
+
exec(open(dir_codes + '/poscar_fix_direct_coord.py').read())
|
|
139
|
+
#=============================================================
|
|
140
|
+
# Checking the structure of POSCAR files, regarding the ======
|
|
141
|
+
# rotation angle in relation to the z-axis ===================
|
|
142
|
+
#=============================================================
|
|
143
|
+
exec(open(dir_codes + '/cell_check.py').read())
|
|
144
|
+
#=============================================================
|
|
145
|
+
|
|
146
|
+
if (loop_ht == 1):
|
|
147
|
+
#--------------
|
|
148
|
+
n_Lattice = 2
|
|
149
|
+
#--------------------------------------------------------------------------
|
|
150
|
+
# Checking for existence of non-empty file 'check_list_loop.txt' ----------
|
|
151
|
+
#--------------------------------------------------------------------------
|
|
152
|
+
temp_check = 0
|
|
153
|
+
#-------------
|
|
154
|
+
check_list_dir = dir_files + '/check_list_loop.txt'
|
|
155
|
+
if os.path.exists(check_list_dir) and os.path.getsize(check_list_dir) != 0:
|
|
156
|
+
check = np.loadtxt(check_list_dir, dtype='str'); check.shape
|
|
157
|
+
n_ht = check[:,0]; mat1 = check[:,1]; mat2 = check[:,2]
|
|
158
|
+
temp_check = 1
|
|
159
|
+
#------------------------------
|
|
160
|
+
if (temp_check == 0): nloop = 0
|
|
161
|
+
if (temp_check == 1): nloop = len(mat1)
|
|
162
|
+
#--------------------------------------
|
|
163
|
+
temp_dir = dir_files + '/' + dir_poscar
|
|
164
|
+
files0 = [name for name in os.listdir(temp_dir) if os.path.isfile(os.path.join(temp_dir, name))] # Listando os arquivos dentro do diretório "dir_poscar"
|
|
165
|
+
files = sorted(files0)
|
|
166
|
+
#---------------------------------------------------------------------
|
|
167
|
+
# bilayer_materials = list(itertools.combinations(files, 2))
|
|
168
|
+
# for material in files: bilayer_materials.append((material, material))
|
|
169
|
+
#---------------------------------------------------------------------
|
|
170
|
+
bilayer_materials = []
|
|
171
|
+
for material1 in files:
|
|
172
|
+
for material2 in files:
|
|
173
|
+
bilayer_materials.append((material1, material2))
|
|
174
|
+
#-------------------------------------------------------
|
|
175
|
+
vistos = set()
|
|
176
|
+
new_bilayer_materials = [] # List to store unique elements
|
|
177
|
+
for elemento in bilayer_materials:
|
|
178
|
+
elem_ordenado = tuple(sorted(elemento)) # Sorts the elements (ignoring permutations)
|
|
179
|
+
if elem_ordenado not in vistos:
|
|
180
|
+
new_bilayer_materials.append(elemento) # Adding elements that do not have permutations
|
|
181
|
+
vistos.add(elem_ordenado)
|
|
182
|
+
bilayer_materials = new_bilayer_materials # Saving the new list with the permutations removed
|
|
183
|
+
#-------------------------------------------------------
|
|
184
|
+
for loop in range(len(bilayer_materials)):
|
|
185
|
+
Lattice1 = bilayer_materials[loop][0]
|
|
186
|
+
Lattice2 = bilayer_materials[loop][1]
|
|
187
|
+
Lattice3 = ''
|
|
188
|
+
#------
|
|
189
|
+
run = 1
|
|
190
|
+
#-------------------
|
|
191
|
+
if (temp_check == 1):
|
|
192
|
+
for mnt in range(len(mat1)):
|
|
193
|
+
temp0_mat1 = str(mat1[mnt]); temp0_mat2 = str(mat2[mnt])
|
|
194
|
+
temp1_mat1 = Lattice1.replace('.vasp', ''); temp1_mat2 = Lattice2.replace('.vasp', '')
|
|
195
|
+
if ( (temp0_mat1 == temp1_mat1 and temp0_mat2 == temp1_mat2) or (temp0_mat1 == temp1_mat2 and temp0_mat2 == temp1_mat1) ): run = 0
|
|
196
|
+
#---------------------------------------------------------------------------------------------------------------------------------
|
|
197
|
+
|
|
198
|
+
if ( temp_check == 0 or (temp_check == 1 and run == 1) ):
|
|
199
|
+
#------------------------------------------------------------------
|
|
200
|
+
# Heterostructure loop check_list ---------------------------------
|
|
201
|
+
#------------------------------------------------------------------
|
|
202
|
+
nloop += +1
|
|
203
|
+
if (nloop >= 0 and nloop < 10): nloop2 = '000' + str(nloop)
|
|
204
|
+
if (nloop >= 10 and nloop < 100): nloop2 = '00' + str(nloop)
|
|
205
|
+
if (nloop >= 100 and nloop < 1000): nloop2 = '0' + str(nloop)
|
|
206
|
+
if (nloop > 1000): nloop2 = str(nloop)
|
|
207
|
+
dir_loop = str(nloop2) + '--' + Lattice1.replace('.vasp', '') + '--' + Lattice2.replace('.vasp', '')
|
|
208
|
+
#---------------------------------------------------------------------------------------------------
|
|
209
|
+
check_list = open(dir_files + '/check_list_loop.txt', 'a')
|
|
210
|
+
t_Lattice1 = Lattice1.replace('.vasp', ' '); t_Lattice2 = Lattice2.replace('.vasp', ' ')
|
|
211
|
+
if (n_Lattice == 2):
|
|
212
|
+
check_list.write(f'{nloop2} {t_Lattice1} {t_Lattice2} \n')
|
|
213
|
+
if (n_Lattice == 3):
|
|
214
|
+
t_Lattice3 = Lattice3.replace('.vasp', ' ')
|
|
215
|
+
check_list.write(f'{nloop2} {t_Lattice1} {t_Lattice2} {t_Lattice3} \n')
|
|
216
|
+
check_list.close()
|
|
217
|
+
#-----------------
|
|
218
|
+
|
|
219
|
+
try:
|
|
220
|
+
exec(open(dir_codes + '/HeteroStructure_Generator.py').read())
|
|
221
|
+
...
|
|
222
|
+
except SystemExit as e: 0 == 0
|
|
223
|
+
except Exception as e: 0 == 0
|
|
224
|
+
#----------------------------
|
|
225
|
+
|
|
226
|
+
if (loop_ht == 0): exec(open(dir_codes + '/HeteroStructure_Generator.py').read())
|
|
227
|
+
|
|
228
|
+
|
|
229
|
+
if (tarefa == 2):
|
|
230
|
+
#-------------------------------------------------------------------------------------------
|
|
231
|
+
# Checking if the "SAMBA_WorkFlow.input" file exists, if it does not exist it is created ---
|
|
232
|
+
#-------------------------------------------------------------------------------------------
|
|
233
|
+
if os.path.isfile(dir_files + '/SAMBA_WorkFlow.input'):
|
|
234
|
+
0 == 0
|
|
235
|
+
else:
|
|
236
|
+
shutil.copyfile(dir_codes + '/SAMBA_WorkFlow.input', dir_files + '/SAMBA_WorkFlow.input')
|
|
237
|
+
#----------------------------------------------------------------------------------------
|
|
238
|
+
print(" ")
|
|
239
|
+
print("==============================================================")
|
|
240
|
+
print("SAMBA_WorkFlow.input file generated !!! ======================")
|
|
241
|
+
print("--------------------------------------------------------------")
|
|
242
|
+
print("Configure the SAMBA_WorkFlow.input file and run the code again")
|
|
243
|
+
print("==============================================================")
|
|
244
|
+
print(" ")
|
|
245
|
+
#--------------------------------------------------------
|
|
246
|
+
confirmacao = input (" "); confirmacao = str(confirmacao)
|
|
247
|
+
sys.exit()
|
|
248
|
+
#---------
|
|
249
|
+
|
|
250
|
+
#----------------------------------------------------
|
|
251
|
+
# Checking if the "WorkFlow_INPUTS" folder exists ---
|
|
252
|
+
#----------------------------------------------------
|
|
253
|
+
if os.path.isdir(dir_files + '/WorkFlow_INPUTS'):
|
|
254
|
+
dir_inputs = dir_files + '/WorkFlow_INPUTS'
|
|
255
|
+
else:
|
|
256
|
+
dir_inputs = dir_codes + '/INPUTS'
|
|
257
|
+
#------------------------------------------------------
|
|
258
|
+
dir_inputs_vasprocar = dir_inputs + '/inputs_VASProcar'
|
|
259
|
+
#------------------------------------------------------
|
|
260
|
+
|
|
261
|
+
#------------------------------------------------
|
|
262
|
+
# Checking if the "POTCAR" folder exists --------
|
|
263
|
+
#------------------------------------------------
|
|
264
|
+
if os.path.isdir(dir_files + '/POTCAR'):
|
|
265
|
+
0 == 0
|
|
266
|
+
else:
|
|
267
|
+
print('')
|
|
268
|
+
print('Warning: -----------------------------------------')
|
|
269
|
+
print('Missing POTCAR folder and POTCAR_[ion] files -----')
|
|
270
|
+
print('Enter and then press [ENTER] to continue ---------')
|
|
271
|
+
print('--------------------------------------------------')
|
|
272
|
+
confirmacao = input (" "); confirmacao = str(confirmacao)
|
|
273
|
+
#------------------------------------
|
|
274
|
+
dir_pseudo = dir_files + '/POTCAR'
|
|
275
|
+
shutil.copyfile(dir_codes + '/_info_pseudo.py', dir_pseudo + '/_info_pseudo.py')
|
|
276
|
+
os.chdir(dir_pseudo)
|
|
277
|
+
exec(open(dir_pseudo + '/_info_pseudo.py').read())
|
|
278
|
+
os.chdir(dir_samba)
|
|
279
|
+
#------------------
|
|
280
|
+
|
|
281
|
+
#-----------------------------------------------------
|
|
282
|
+
exec(open(dir_files + '/SAMBA_WorkFlow.input').read())
|
|
283
|
+
#-----------------------------------------------------
|
|
284
|
+
vacuo = vacuum
|
|
285
|
+
#-------------
|
|
286
|
+
dir_out = dir_files + '/' + dir_o
|
|
287
|
+
#----------------------------------
|
|
288
|
+
task = []
|
|
289
|
+
for i in range(len(tasks)):
|
|
290
|
+
if (tasks[i] == 'a-scan' or tasks[i] == 'z-scan' or tasks[i] == 'xy-scan' or tasks[i] == 'xyz-scan' or tasks[i] == 'relax'): task.append(tasks[i])
|
|
291
|
+
for j in range(len(type)):
|
|
292
|
+
if (type[j] == 'sem_SO'): rot = ''
|
|
293
|
+
if (type[j] == 'com_SO'): rot = '.SO'
|
|
294
|
+
if (tasks[i] != 'a-scan' and tasks[i] != 'z-scan' and tasks[i] != 'xy-scan' and tasks[i] != 'xyz-scan' and tasks[i] != 'relax'): task.append(tasks[i] + rot)
|
|
295
|
+
#--------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
|
296
|
+
|
|
297
|
+
#=============================================================
|
|
298
|
+
# Fixing the coordinates of POSCAR files in direct form ======
|
|
299
|
+
#=============================================================
|
|
300
|
+
dir_files_in = 'Structures'
|
|
301
|
+
exec(open(dir_codes + '/poscar_fix_direct_coord.py').read())
|
|
302
|
+
#=============================================================
|
|
303
|
+
exec(open(dir_codes + '/make_files.py').read())
|
|
304
|
+
#=============================================================
|
|
305
|
+
|
|
306
|
+
|
|
307
|
+
if (tarefa == 3): shutil.copytree(dir_codes + '/INPUTS', dir_files + '/WorkFlow_INPUTS')
|
|
308
|
+
|
|
309
|
+
|
|
310
|
+
print(" ")
|
|
311
|
+
print("=============")
|
|
312
|
+
print("Completed ===")
|
|
313
|
+
print("=============")
|
|
314
|
+
print(" ")
|
|
315
|
+
|
|
316
|
+
if __name__ == '__main__':
|
|
317
|
+
main()
|
|
@@ -6,10 +6,14 @@ import json
|
|
|
6
6
|
|
|
7
7
|
setup(
|
|
8
8
|
name = "SAMBA_ilum",
|
|
9
|
-
version = "1.1.0.
|
|
10
|
-
|
|
9
|
+
version = "1.1.0.117",
|
|
10
|
+
# Define os pacotes a serem incluídos
|
|
11
|
+
# Isso empacotará tanto samba_ilum quanto samba_ilum.src
|
|
12
|
+
packages=['samba_ilum', 'samba_ilum.src'],
|
|
13
|
+
# A entrada principal para o comando do terminal
|
|
14
|
+
entry_points={'console_scripts': ['samba_ilum = samba_ilum.__main__:main']},
|
|
11
15
|
description = "...",
|
|
12
|
-
author = "Augusto de Lelis Araujo",
|
|
16
|
+
author = "Augusto de Lelis Araujo",
|
|
13
17
|
author_email = "augusto-lelis@outlook.com",
|
|
14
18
|
license = "Closed source",
|
|
15
19
|
install_requires=['matplotlib',
|
|
@@ -21,7 +25,8 @@ setup(
|
|
|
21
25
|
'numpy',
|
|
22
26
|
'uuid',
|
|
23
27
|
'vasprocar'],
|
|
24
|
-
|
|
28
|
+
# Garante que os arquivos .dat, .png, etc. sejam incluídos
|
|
29
|
+
package_data={'samba_ilum': ['*.dat', '*.png', '*.jpg', '*']},
|
|
25
30
|
)
|
|
26
31
|
|
|
27
32
|
# python3 -m pip install --upgrade twine
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
LICENSE.txt
|
|
2
|
-
README.md
|
|
3
|
-
setup.cfg
|
|
4
|
-
setup.py
|
|
5
|
-
SAMBA_ilum.egg-info/PKG-INFO
|
|
6
|
-
SAMBA_ilum.egg-info/SOURCES.txt
|
|
7
|
-
SAMBA_ilum.egg-info/dependency_links.txt
|
|
8
|
-
SAMBA_ilum.egg-info/entry_points.txt
|
|
9
|
-
SAMBA_ilum.egg-info/requires.txt
|
|
10
|
-
SAMBA_ilum.egg-info/top_level.txt
|
|
11
|
-
samba_ilum/__init__.py
|
|
12
|
-
samba_ilum/__main__.py
|
|
13
|
-
samba_ilum/src/BZ_2D.py
|
|
14
|
-
samba_ilum/src/HeteroStructure_Generator.py
|
|
15
|
-
samba_ilum/src/_info_pseudo.py
|
|
16
|
-
samba_ilum/src/a-scan.py
|
|
17
|
-
samba_ilum/src/a-scan_analysis.py
|
|
18
|
-
samba_ilum/src/bader
|
|
19
|
-
samba_ilum/src/bader_poscar.py
|
|
20
|
-
samba_ilum/src/bader_update.py
|
|
21
|
-
samba_ilum/src/cell_check.py
|
|
22
|
-
samba_ilum/src/charge_transfer.py
|
|
23
|
-
samba_ilum/src/chgsum.pl
|
|
24
|
-
samba_ilum/src/contcar_update.py
|
|
25
|
-
samba_ilum/src/data-base_json.py
|
|
26
|
-
samba_ilum/src/data-base_union.py
|
|
27
|
-
samba_ilum/src/energy_scan.py
|
|
28
|
-
samba_ilum/src/hubbard_correction.py
|
|
29
|
-
samba_ilum/src/job.py
|
|
30
|
-
samba_ilum/src/kpoints.py
|
|
31
|
-
samba_ilum/src/lattice_plot3d.py
|
|
32
|
-
samba_ilum/src/make_files.py
|
|
33
|
-
samba_ilum/src/output.py
|
|
34
|
-
samba_ilum/src/poscar_fix_direct_coord.py
|
|
35
|
-
samba_ilum/src/potcar.py
|
|
36
|
-
samba_ilum/src/vdW_DF.py
|
|
37
|
-
samba_ilum/src/xy-scan.py
|
|
38
|
-
samba_ilum/src/xy-scan_analysis.py
|
|
39
|
-
samba_ilum/src/xyz-scan.py
|
|
40
|
-
samba_ilum/src/xyz-scan_analysis.py
|
|
41
|
-
samba_ilum/src/z-scan.py
|
|
42
|
-
samba_ilum/src/z-scan_analysis.py
|
|
43
|
-
samba_ilum/src/INPUTS/Hubbard_U_values.txt
|
|
44
|
-
samba_ilum/src/INPUTS/INCAR_a-scan
|
|
45
|
-
samba_ilum/src/INPUTS/INCAR_bader
|
|
46
|
-
samba_ilum/src/INPUTS/INCAR_bader.SO
|
|
47
|
-
samba_ilum/src/INPUTS/INCAR_bands
|
|
48
|
-
samba_ilum/src/INPUTS/INCAR_bands.SO
|
|
49
|
-
samba_ilum/src/INPUTS/INCAR_dos
|
|
50
|
-
samba_ilum/src/INPUTS/INCAR_dos.SO
|
|
51
|
-
samba_ilum/src/INPUTS/INCAR_relax
|
|
52
|
-
samba_ilum/src/INPUTS/INCAR_scf
|
|
53
|
-
samba_ilum/src/INPUTS/INCAR_scf.SO
|
|
54
|
-
samba_ilum/src/INPUTS/INCAR_xy-scan
|
|
55
|
-
samba_ilum/src/INPUTS/INCAR_xyz-scan
|
|
56
|
-
samba_ilum/src/INPUTS/INCAR_z-scan
|
|
57
|
-
samba_ilum/src/INPUTS/SAMBA_HeteroStructure.input
|
|
58
|
-
samba_ilum/src/INPUTS/SAMBA_WorkFlow.input
|
|
59
|
-
samba_ilum/src/INPUTS/vdw_kernel.bindat
|
|
60
|
-
samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.bands
|
|
61
|
-
samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.chgcar
|
|
62
|
-
samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.dos
|
|
63
|
-
samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.location
|
|
64
|
-
samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.locpot
|
|
65
|
-
samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.orbitals
|
|
66
|
-
samba_ilum/src/INPUTS/inputs_VASProcar/input.vasprocar.spin
|