From 568935d114dd0aaf443361f61e56a927fee1ad67 Mon Sep 17 00:00:00 2001 From: ThueCTN <57895175+vanitery@users.noreply.github.com> Date: Wed, 13 Sep 2023 12:20:37 +0200 Subject: [PATCH] Update process_file.py Changing from "np.float" to the built-in "float", since the numpy alias has been deprecated since 1.20, and has been stopping compilation in Python 3.11.4 kernels using VS Code. The change should be safe and otherwise inconsequential, pending verification. --- scraps/process_file.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scraps/process_file.py b/scraps/process_file.py index 109861b..4e47098 100644 --- a/scraps/process_file.py +++ b/scraps/process_file.py @@ -53,12 +53,12 @@ def process_file(fileName, mask = None, meta_only=False, **loadtxt_kwargs): #Read the temp, pwr, and resName from the filename if(fileName[tempLoc + 1] == '.'): - temp = np.float(fileName[tempLoc:tempLoc+5]) + temp = float(fileName[tempLoc:tempLoc+5]) if fileName[pwrLoc] == '_': - pwr = np.float(fileName[pwrLoc+1:pwrLoc+3]) + pwr = float(fileName[pwrLoc+1:pwrLoc+3]) else: - pwr = np.float(fileName[pwrLoc:pwrLoc+3]) + pwr = float(fileName[pwrLoc:pwrLoc+3]) resName = fileName[resNameLoc:resNameLoc+5] @@ -82,4 +82,4 @@ def process_file(fileName, mask = None, meta_only=False, **loadtxt_kwargs): return retVal else: - assert False, "Bad file? " + fileName \ No newline at end of file + assert False, "Bad file? " + fileName