From 8463d78e072ae26108ea1d2a66211aa8ac9f9e72 Mon Sep 17 00:00:00 2001 From: Anne Philipp <anne.philipp@univie.ac.at> Date: Tue, 30 Jul 2019 09:56:59 +0200 Subject: [PATCH] made python3 again, now working --- Source/Python/Classes/ControlFile.py | 2 +- Source/Python/Classes/EcFlexpart.py | 6 +++--- Source/Python/Classes/GribUtil.py | 2 +- Source/Python/Classes/MarsRetrieval.py | 2 +- Source/Python/Classes/UioFiles.py | 2 +- Source/Python/Mods/checks.py | 2 +- Source/Python/Mods/disaggregation.py | 2 +- Source/Python/Mods/get_mars_data.py | 2 +- Source/Python/Mods/prepare_flexpart.py | 2 +- Source/Python/Mods/profiling.py | 2 +- Source/Python/Mods/tools.py | 2 +- Source/Python/_config.py | 2 +- Source/Python/install.py | 2 +- Source/Python/submit.py | 2 +- Templates/compilejob.template | 8 ++++---- Templates/job.temp | 8 ++++---- Templates/job.template | 8 ++++---- 17 files changed, 28 insertions(+), 28 deletions(-) diff --git a/Source/Python/Classes/ControlFile.py b/Source/Python/Classes/ControlFile.py index 6665ae6..5fd1798 100644 --- a/Source/Python/Classes/ControlFile.py +++ b/Source/Python/Classes/ControlFile.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Leopold Haimberger (University of Vienna) diff --git a/Source/Python/Classes/EcFlexpart.py b/Source/Python/Classes/EcFlexpart.py index a8cc86d..7326e86 100644 --- a/Source/Python/Classes/EcFlexpart.py +++ b/Source/Python/Classes/EcFlexpart.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Fouilloux (University of Oslo) @@ -845,8 +845,8 @@ class EcFlexpart(object): if area[1] > area[3]: area[1] -= 360 - maxl = round((area[3] - area[1]) / grid[1]) + 1 - maxb = round((area[0] - area[2]) / grid[0]) + 1 + maxl = int(round((area[3] - area[1]) / grid[1])) + 1 + maxb = int(round((area[0] - area[2]) / grid[0])) + 1 stream = namelist_template.generate( maxl = str(maxl), diff --git a/Source/Python/Classes/GribUtil.py b/Source/Python/Classes/GribUtil.py index 2bbdf74..b7a66a2 100644 --- a/Source/Python/Classes/GribUtil.py +++ b/Source/Python/Classes/GribUtil.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Fouilloux (University of Oslo) diff --git a/Source/Python/Classes/MarsRetrieval.py b/Source/Python/Classes/MarsRetrieval.py index a1b843e..c87f878 100644 --- a/Source/Python/Classes/MarsRetrieval.py +++ b/Source/Python/Classes/MarsRetrieval.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Fouilloux (University of Oslo) diff --git a/Source/Python/Classes/UioFiles.py b/Source/Python/Classes/UioFiles.py index a091ddc..8c1c269 100644 --- a/Source/Python/Classes/UioFiles.py +++ b/Source/Python/Classes/UioFiles.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Fouilloux (University of Oslo) diff --git a/Source/Python/Mods/checks.py b/Source/Python/Mods/checks.py index 0250ffe..54db0dc 100644 --- a/Source/Python/Mods/checks.py +++ b/Source/Python/Mods/checks.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Philipp (University of Vienna) diff --git a/Source/Python/Mods/disaggregation.py b/Source/Python/Mods/disaggregation.py index 5407ca1..a5d36ca 100644 --- a/Source/Python/Mods/disaggregation.py +++ b/Source/Python/Mods/disaggregation.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Philipp (University of Vienna) diff --git a/Source/Python/Mods/get_mars_data.py b/Source/Python/Mods/get_mars_data.py index 2329b84..e3c7947 100755 --- a/Source/Python/Mods/get_mars_data.py +++ b/Source/Python/Mods/get_mars_data.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Fouilloux (University of Oslo) diff --git a/Source/Python/Mods/prepare_flexpart.py b/Source/Python/Mods/prepare_flexpart.py index efa4f5e..ba4026e 100755 --- a/Source/Python/Mods/prepare_flexpart.py +++ b/Source/Python/Mods/prepare_flexpart.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Fouilloux (University of Oslo) diff --git a/Source/Python/Mods/profiling.py b/Source/Python/Mods/profiling.py index f89e672..c95e4e0 100644 --- a/Source/Python/Mods/profiling.py +++ b/Source/Python/Mods/profiling.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #************************************************************************ # ToDo AP diff --git a/Source/Python/Mods/tools.py b/Source/Python/Mods/tools.py index 0a43102..5b57f30 100644 --- a/Source/Python/Mods/tools.py +++ b/Source/Python/Mods/tools.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Philipp (University of Vienna) diff --git a/Source/Python/_config.py b/Source/Python/_config.py index 16a5940..591a6c9 100644 --- a/Source/Python/_config.py +++ b/Source/Python/_config.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Philipp (University of Vienna) diff --git a/Source/Python/install.py b/Source/Python/install.py index 4d408ff..172a060 100755 --- a/Source/Python/install.py +++ b/Source/Python/install.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Leopold Haimberger (University of Vienna) diff --git a/Source/Python/submit.py b/Source/Python/submit.py index 478dad5..399ffba 100755 --- a/Source/Python/submit.py +++ b/Source/Python/submit.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- #******************************************************************************* # @Author: Anne Fouilloux (University of Oslo) diff --git a/Templates/compilejob.template b/Templates/compilejob.template index bf83f18..d96c165 100644 --- a/Templates/compilejob.template +++ b/Templates/compilejob.template @@ -31,8 +31,8 @@ case $${HOST} in module unload eccodes module unload python module unload emos - module load python - module load eccodes/2.12.0 + module load python3/3.6.8-01 + module load eccodes/2.12.5 module load emos/455-r64 export FLEXPART_ROOT_SCRIPTS=$fp_root_scripts export MAKEFILE=$makefile @@ -41,8 +41,8 @@ case $${HOST} in module unload python module switch PrgEnv-cray PrgEnv-intel module load python3 - module load eccodes/2.12.0 - module load emos + module load eccodes/2.12.5 + module load emos/455-r64 echo $${GROUP} echo $${HOME} echo $${HOME} | awk -F / '{print $1, $2, $3, $4}' diff --git a/Templates/job.temp b/Templates/job.temp index 9224735..df2e537 100644 --- a/Templates/job.temp +++ b/Templates/job.temp @@ -31,8 +31,8 @@ case $${HOST} in module unload eccodes module unload python module unload emos - module load python/2.7.15-01 - module load eccodes/2.12.0 + module load python3/3.6.8-01 + module load eccodes/2.12.5 module load emos/455-r64 export PATH=$${PATH}:$${HOME}/flex_extract_v7.1/Source/Python ;; @@ -40,8 +40,8 @@ case $${HOST} in module unload python module switch PrgEnv-cray PrgEnv-intel module load python3 - module load eccodes/2.12.0 - module load emos + module load eccodes/2.12.5 + module load emos/455-r64 export SCRATCH=$${TMPDIR} export PATH=$${PATH}:$${HOME}/flex_extract_v7.1/Source/Python ;; diff --git a/Templates/job.template b/Templates/job.template index 32ddd25..bdd1151 100644 --- a/Templates/job.template +++ b/Templates/job.template @@ -31,8 +31,8 @@ case $$$${HOST} in module unload eccodes module unload python module unload emos - module load python - module load eccodes/2.12.0 + module load python3/3.6.8-01 + module load eccodes/2.12.5 module load emos/455-r64 export PATH=$$$${PATH}:$fp_root_path ;; @@ -40,8 +40,8 @@ case $$$${HOST} in module unload python module switch PrgEnv-cray PrgEnv-intel module load python3 - module load eccodes/2.12.0 - module load emos + module load eccodes/2.12.5 + module load emos/455-r64 export SCRATCH=$$$${TMPDIR} export PATH=$$$${PATH}:$fp_root_path ;; -- GitLab