@@ -119,9 +119,9 @@ def calculate_eta_and_max_diff(
119
119
weight_a = bandsdata_a .get ("weights" )
120
120
weight_b = bandsdata_b .get ("weights" )
121
121
weight = weight_a
122
- assert np .allclose (
123
- weight_a , weight_b
124
- ), "Different weight of kpoints of two calculation."
122
+ assert np .allclose (weight_a , weight_b ), (
123
+ "Different weight of kpoints of two calculation."
124
+ )
125
125
126
126
bands_a = bandsdata_a .get ("bands" )
127
127
bands_b = bandsdata_b .get ("bands" )
@@ -205,10 +205,11 @@ def get_bands_distance(
205
205
# swap to make sure a is less electrons pseudo
206
206
bandsdata_a , bandsdata_b = bandsdata_b , bandsdata_a
207
207
208
- assert (
209
- int (bandsdata_b ["number_of_electrons" ])
210
- >= int (bandsdata_a ["number_of_electrons" ])
211
- ), f"Need to be less num_bands in a { bandsdata_a ['number_of_electrons' ]} than b { bandsdata_b ['number_of_electrons' ]} "
208
+ assert int (bandsdata_b ["number_of_electrons" ]) >= int (
209
+ bandsdata_a ["number_of_electrons" ]
210
+ ), (
211
+ f"Need to be less num_bands in a { bandsdata_a ['number_of_electrons' ]} than b { bandsdata_b ['number_of_electrons' ]} "
212
+ )
212
213
213
214
num_electrons_a = int (bandsdata_a ["number_of_electrons" ])
214
215
num_electrons_b = int (bandsdata_b ["number_of_electrons" ])
@@ -238,9 +239,9 @@ def get_bands_distance(
238
239
239
240
# after cut and align in retrive band, the shapes are same now
240
241
# import ipdb; ipdb.set_trace()
241
- assert np .shape (bandsdata_a ["bands" ]) == np .shape (
242
- bandsdata_b [" bands" ]
243
- ), f' { np . shape ( bandsdata_a [ "bands" ]) } != { np . shape ( bandsdata_b [ "bands" ]) } '
242
+ assert np .shape (bandsdata_a ["bands" ]) == np .shape (bandsdata_b [ "bands" ]), (
243
+ f" { np . shape ( bandsdata_a [ 'bands' ]) } != { np . shape ( bandsdata_b [' bands' ]) } "
244
+ )
244
245
245
246
# eta_v
246
247
fermi_shift_v = 0.0
0 commit comments