Function argument name fix

Former-commit-id: fc94fe122c9c8e9eb3f0a0b125db79a0a238fee7
This commit is contained in:
Marek Nečada 2018-09-22 23:05:37 +03:00
parent ea2ec950c9
commit 95eaea1b4b
1 changed files with 5 additions and 4 deletions

View File

@ -8,6 +8,7 @@ from scipy.special import lpmn, lpmv, sph_jn, sph_yn, poch, gammaln
from scipy.misc import factorial
import math
import cmath
import os
"""
'''
@ -847,7 +848,7 @@ def processWfiles_sameKs(freqfilenames, destfilename, lMax = None, f='npz'):
k0s[succread] = data[0,2] # TODO check this as well?
EeVs[succread] = data[0,1]
succread += 1
allWs.close()
del allWs
freqs = freqs_weirdunits * c / um
if f == 'npz':
@ -882,19 +883,19 @@ def processWfiles_sameKs(freqfilenames, destfilename, lMax = None, f='npz'):
def loadWfile_processed(fileName, lMax = None, fatForm = True, midk_halfwidth = None):
if os.path.isdir(fileName): # .npy files in a directory
p = filename
p = fileName
j = os.path.join
nk = np.load(j(p,'nk.npy'))[()]
nfreqs = np.load(j(p,'nfreqs.npy'))[()]
nparticles = np.load(j(p,'npart.npy'))[()]
Ws = np.load(j(p,'Wdata.npy'), mode='r')
Ws = np.load(j(p,'Wdata.npy'), mmap_mode='r')
ks = np.load(j(p,'ks.npy'))
freqs = np.load(j(p,'freqs.npy'))
k0s = np.load(j(p,'k0s.npy'))
EeVs_orig = np.load(j(p,'EeVs_orig.npy'))
freqs_weirdunits = np.load(j(p,'freqs_weirdunits.npy'))
else: # npz file
data = np.load(fileName, mode='r')
data = np.load(fileName, mmap_mode='r')
nk = data['nk'][()]
nfreqs = data['nfreqs'][()]
nparticles = data['npart'][()]