python-Error
Nazari-Fariba opened this issue · 7 comments
There exist python error for running BoltzTrap_Tools
DATA_Process(Analyse,File_DATA,Ef,labels)File "build/bdist.macosx-10.13 x86_64/egg/BoltzTraP_Tools/BoltzTraP_Tools.py", line 337, in DATA_Process
File "build/bdist.macosx-10.13-x86_64/egg/BoltzTraP_Tools/BoltzTraP_Tools.py", line 311, in Get_DATA
UnboundLocalError: local variable 'DATA' referenced before assignment
Regards
Fariba
IASBS
Hi,
From first look it seems that your Type variable is not corresponding to the allowed value;
Type must be on of the following string :[ "Trace", "Condtens", "N-Condtens", "N-Trace"].
If you still have the same error, please give all steps to reproduce the error.
Hi
I still have the same error.
here is the g-test.scf.in&control
calculation='scf'
restart_mode='from_scratch',
pseudo_dir = '/home/nafiseh/pseudo',
outdir='/home/nafiseh/BT_FARIBA/data/g-test/'
prefix='g-test'
verbosity='high'
/
&system
ibrav = 0,
celldm(1) = 1.8897261249935,
nat = 2
ntyp = 1,
ecutwfc =40.0
occupations='smearing', smearing='cold', degauss=0.02
/
&electrons
startingwfc='random'
diagonalization='cg'
conv_thr = 1.0e-8
/
CELL_PARAMETERS cubic
2.1304215583 -1.2299994602 0.0000000000
0.0000000000 2.4599989204 0.0000000000
0.0000000000 0.0000000000 6.8000000000
ATOMIC_SPECIES
C 12 C.pz-vbc.UPF
ATOMIC_POSITIONS crystal
C 0.0000000000 0.0000000000 0.2500000000
C 0.3333333333 0.6666666667 0.2500000000
K_POINTS (automatic)
10 10 10 0 0 0
- pw.x <g-test.scf.in> g-test.scf.out
Here is the g-test.nscf.in&control
calculation='nscf'
restart_mode='from_scratch',
pseudo_dir = '/home/nafiseh/pseudo',
outdir='/home/nafiseh/BT_FARIBA/data/g-test/'
prefix='g-test'
verbosity='high'
/
&system
ibrav = 0,
celldm(1) = 1.8897261249935,
nat = 2
ntyp = 1,
ecutwfc =40.0
occupations='smearing', smearing='cold', degauss=0.02
/
&electrons
startingwfc='random'
diagonalization='cg'
conv_thr = 1.0e-8
/
CELL_PARAMETERS cubic
2.1304215583 -1.2299994602 0.0000000000
0.0000000000 2.4599989204 0.0000000000
0.0000000000 0.0000000000 6.8000000000
ATOMIC_SPECIES
C 12 C.pz-vbc.UPF
ATOMIC_POSITIONS crystal
C 0.0000000000 0.0000000000 0.2500000000
C 0.3333333333 0.6666666667 0.2500000000
K_POINTS
64
0.00000000 0.00000000 0.00000000 1.562500e-02
0.00000000 0.00000000 0.25000000 1.562500e-02
0.00000000 0.00000000 0.50000000 1.562500e-02
0.00000000 0.00000000 0.75000000 1.562500e-02
0.00000000 0.25000000 0.00000000 1.562500e-02
0.00000000 0.25000000 0.25000000 1.562500e-02
0.00000000 0.25000000 0.50000000 1.562500e-02
0.00000000 0.25000000 0.75000000 1.562500e-02
0.00000000 0.50000000 0.00000000 1.562500e-02
0.00000000 0.50000000 0.25000000 1.562500e-02
0.00000000 0.50000000 0.50000000 1.562500e-02
0.00000000 0.50000000 0.75000000 1.562500e-02
0.00000000 0.75000000 0.00000000 1.562500e-02
0.00000000 0.75000000 0.25000000 1.562500e-02
0.00000000 0.75000000 0.50000000 1.562500e-02
0.00000000 0.75000000 0.75000000 1.562500e-02
0.25000000 0.00000000 0.00000000 1.562500e-02
0.25000000 0.00000000 0.25000000 1.562500e-02
0.25000000 0.00000000 0.50000000 1.562500e-02
0.25000000 0.00000000 0.75000000 1.562500e-02
0.25000000 0.25000000 0.00000000 1.562500e-02
0.25000000 0.25000000 0.25000000 1.562500e-02
0.25000000 0.25000000 0.50000000 1.562500e-02
0.25000000 0.25000000 0.75000000 1.562500e-02
0.25000000 0.50000000 0.00000000 1.562500e-02
0.25000000 0.50000000 0.25000000 1.562500e-02
0.25000000 0.50000000 0.50000000 1.562500e-02
0.25000000 0.50000000 0.75000000 1.562500e-02
0.25000000 0.75000000 0.00000000 1.562500e-02
0.25000000 0.75000000 0.25000000 1.562500e-02
0.25000000 0.75000000 0.50000000 1.562500e-02
0.25000000 0.75000000 0.75000000 1.562500e-02
0.50000000 0.00000000 0.00000000 1.562500e-02
0.50000000 0.00000000 0.25000000 1.562500e-02
0.50000000 0.00000000 0.50000000 1.562500e-02
0.50000000 0.00000000 0.75000000 1.562500e-02
0.50000000 0.25000000 0.00000000 1.562500e-02
0.50000000 0.25000000 0.25000000 1.562500e-02
0.50000000 0.25000000 0.50000000 1.562500e-02
0.50000000 0.25000000 0.75000000 1.562500e-02
0.50000000 0.50000000 0.00000000 1.562500e-02
0.50000000 0.50000000 0.25000000 1.562500e-02
0.50000000 0.50000000 0.50000000 1.562500e-02
0.50000000 0.50000000 0.75000000 1.562500e-02
0.50000000 0.75000000 0.00000000 1.562500e-02
0.50000000 0.75000000 0.25000000 1.562500e-02
0.50000000 0.75000000 0.50000000 1.562500e-02
0.50000000 0.75000000 0.75000000 1.562500e-02
0.75000000 0.00000000 0.00000000 1.562500e-02
0.75000000 0.00000000 0.25000000 1.562500e-02
0.75000000 0.00000000 0.50000000 1.562500e-02
0.75000000 0.00000000 0.75000000 1.562500e-02
0.75000000 0.25000000 0.00000000 1.562500e-02
0.75000000 0.25000000 0.25000000 1.562500e-02
0.75000000 0.25000000 0.50000000 1.562500e-02
0.75000000 0.25000000 0.75000000 1.562500e-02
0.75000000 0.50000000 0.00000000 1.562500e-02
0.75000000 0.50000000 0.25000000 1.562500e-02
0.75000000 0.50000000 0.50000000 1.562500e-02
0.75000000 0.50000000 0.75000000 1.562500e-02
0.75000000 0.75000000 0.00000000 1.562500e-02
0.75000000 0.75000000 0.25000000 1.562500e-02
0.75000000 0.75000000 0.50000000 1.562500e-02
0.75000000 0.75000000 0.75000000 1.562500e-02 - pw.x <g-test.nscf.in> g-test.nscf.out
here is the g-test.bands.in input
&BANDS
prefix='g-test'
outdir='/home/nafiseh/BT_FARIBA/data/g-test/'
filband ='g-test.bands.dat',
no_overlap=.true.
/ - bands.x g-test.bands.in g-test.bands.out
- qe2boltz.py g-test pw 1.0e7 0
- x_trans BoltzTraP
6)/........../BoltzTraP_Tools-master/scripts/Script_S_scaling.py home/iasbstcc/software/BoltzTraP_Tools-master/scripts/Script_S_scaling.py
Setting of Units and Scale Factors (y/n) ? > n
File Extension (Trace, Condtens, N-Trace, or N-Condtens) ? > trace
trace File name ? > g-test.trace
Fermi Level Value in Ry ? > 0.23
================================================================================
Doping Carrier Concentrations (/uc) : [ 50. 100. 150. 200. 250. 300. 350. 400. 450. 500. 550. 600.
-
-
- 800.]
Give a Doping Value from above > 200.0
200.0
Give the Cell Volume in cm^3 to convert N ; else give 1.0) > 1.0
Traceback (most recent call last):
File "/home/iasbstcc/software/BoltzTraP_Tools-master/scripts/Script_S_scaling.py", line 10, in
DATA_Process(Analyse,File_DATA,Ef,labels)
File "build/bdist.linux-x86_64/egg/BoltzTraP_Tools/BoltzTraP_Tools.py", line 339, in DATA_Process
File "build/bdist.linux-x86_64/egg/BoltzTraP_Tools/BoltzTraP_Tools.py", line 312, in Get_DATA
UnboundLocalError: local variable 'DATA' referenced before assignment
- 800.]
-
Hi,
File Extension (Trace, Condtens, N-Trace, or N-Condtens) ? > trace
Trace != trace
In python the equal operator on string is case sensitive!
Hi
I have checked this. But still I have the same error.
Setting of Units and Scale Factors (y/n) ? > n
File Extension (Trace, Condtens, N-Trace, or N-Condtens) ? > Trace
Trace File name ? > g-test.Trace
Fermi Level Value in Ry ? > 0.23
Parse at fixed Temperature or Energy ? (T/E) > E
Log Scale for Carrier Concentration ? (y/n) > n
Xplot (E, T, N, DOS, S, Sigma, PF, R_H, Kappa, C or Chi ) ? > DOS
Yplot (E, T, N, DOS, S, Sigma, PF, R_H, Kappa, C or Chi ) ? > T
Doping Carrier Concentrations (/uc) : [ 50. 100. 150. 200. 250. 300. 350. 400. 450. 500. 550. 600.
650. 700. 750. 800.]
Give a Doping Value from above > 50.0
50.0
Give the Cell Volume in cm^3 to convert N ; else give 1.0) > 1.0
Traceback (most recent call last):
File "/home/iasbstcc/software/BoltzTraP_Tools-master/scripts/Script_S_scaling.py", line 10, in
DATA_Process(Analyse,File_DATA,Ef,labels)
File "build/bdist.linux-x86_64/egg/BoltzTraP_Tools/BoltzTraP_Tools.py", line 339, in DATA_Process
File "build/bdist.linux-x86_64/egg/BoltzTraP_Tools/BoltzTraP_Tools.py", line 312, in Get_DATA
UnboundLocalError: local variable 'DATA' referenced before assignment
Can you attach the trace file
Here is the Trace file