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