Skip to content

Commit 3befca2

Browse files
committed
Fixed NumPy 2.4.3 compatibility issue, updated CI scripts
1 parent f25bef6 commit 3befca2

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

.github/scripts/gmsvtoolkit-build-ci.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ echo "===================FFTW=================="
5959
mkdir -p ${FFTW_BUILD_DIR}
6060
OLD_DIR=`pwd`
6161
cd ${FFTW_BUILD_DIR}
62-
download_untar https://g-c662a6.a78b8.36fe.data.globus.org/bbp/releases/${VERSION}/fftw-3.3.8.tar.gz
62+
download_untar https://g-3a9041.a78b8.36fe.data.globus.org/bbp/releases/${VERSION}/fftw-3.3.8.tar.gz
6363
cd fftw-3.3.8
6464
./configure --prefix=${FFTW_INSTALL_DIR}
6565
make

.github/workflows/gmsvtoolkit-ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
- name: set GMSVTOOLKIT_DIR
1313
run: echo "GMSVTOOLKIT_BASE_DIR=$RUNNER_WORKSPACE/gmsvtoolkit" >> $GITHUB_ENV
1414
- name: Setup Python ${{ matrix.python-version }}
15-
uses: actions/setup-python@v4
15+
uses: actions/setup-python@v6
1616
with:
1717
python-version: ${{ matrix.python-version }}
1818
- name: configure Python
@@ -24,7 +24,7 @@ jobs:
2424
pip install scipy
2525
pip install matplotlib
2626
- name: checkout GMSVToolkit
27-
uses: actions/checkout@v3
27+
uses: actions/checkout@v6
2828
- name: build gmsvtoolkit
2929
run: ./.github/scripts/gmsvtoolkit-build-ci.sh
3030
shell: bash

gmsvtoolkit/models/pynga/__init__.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -284,9 +284,9 @@ def NGA08(model_name, Mw, Rjb, Vs30, period, epislon=0, NGAs=None,
284284
values[:, icmp] = np.exp(values[:, icmp])
285285

286286
# outputs
287-
NGAsigmaT = np.array(values[:, 1]).astype(float)
288-
NGAtau = np.array(values[:, 2]).astype(float)
289-
NGAsigma = np.array(values[:, 3]).astype(float)
287+
NGAsigmaT = np.array(values[:, 1][0], dtype=float)
288+
NGAtau = np.array(values[:, 2][0], dtype=float)
289+
NGAsigma = np.array(values[:, 3][0], dtype=float)
290290
if epislon:
291291
NGAmedian = np.exp(np.log(values[:, 0]) + epislon * NGAsigmaT)
292292
else:

0 commit comments

Comments
 (0)