Skip to content

Commit

Permalink
Merge pull request #696 from alinelena/update_workflows
Browse files Browse the repository at this point in the history
test against various python versions
ilyes319 authored Jan 22, 2025

Verified

This commit was signed with the committer’s verified signature.
kayabaNerve Luke Parker
2 parents e0f7a5b + 3db1754 commit 4b9b13a
Showing 2 changed files with 11 additions and 5 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/unittest.yaml
Original file line number Diff line number Diff line change
@@ -7,11 +7,17 @@ on:
jobs:
pytest-general:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8','3.9','3.10','3.11','3.12']

steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- name: checkout
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: "3.10"
python-version: ${{ matrix.python-version }}
cache: "pip"

- name: Install requirements (general tests)
4 changes: 2 additions & 2 deletions mace/calculators/mace.py
Original file line number Diff line number Diff line change
@@ -8,7 +8,7 @@
import logging
from glob import glob
from pathlib import Path
from typing import Union
from typing import List, Union

import numpy as np
import torch
@@ -53,7 +53,7 @@ class MACECalculator(Calculator):
def __init__(
self,
model_paths: Union[list, str, None] = None,
models: Union[list[torch.nn.Module], torch.nn.Module, None] = None,
models: Union[List[torch.nn.Module], torch.nn.Module, None] = None,
device: str = "cpu",
energy_units_to_eV: float = 1.0,
length_units_to_A: float = 1.0,

0 comments on commit 4b9b13a

Please sign in to comment.