Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
key: ${{ github.ref }}
path: .cache
- name: Set up python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Upgrade pip
Expand All @@ -44,21 +44,20 @@ jobs:
fail-fast: false
matrix:
include:
- {python-version: "3.9", backend: "numpy", os: ubuntu-latest, coverage: True, minimal: True, full: True}
- {python-version: "3.10", backend: "numpy", os: ubuntu-latest, coverage: True, minimal: True, full: True}
- {python-version: "3.11", backend: "numpy", os: ubuntu-latest, coverage: True, minimal: True, full: True}
- {python-version: "3.12", backend: "numpy", os: ubuntu-latest, coverage: False, minimal: True, full: True}
- {python-version: "3.12", backend: "tensorflow", os: ubuntu-latest, coverage: False, minimal: True, full: False}
- {python-version: "3.12", backend: "jax", os: ubuntu-latest, coverage: False, minimal: True, full: False}

steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
key: ${{ github.ref }}
path: .cache
- name: Set up python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Upgrade pip
Expand Down Expand Up @@ -97,13 +96,13 @@ jobs:
if: github.ref == 'refs/heads/master'

steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
key: ${{ github.ref }}
path: .cache
- name: Set up python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Upgrade pip
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ jobs:
id-token: write

steps:
- uses: actions/checkout@v2
- name: Set up python "3.9"
uses: actions/setup-python@v2
- uses: actions/checkout@v4
- name: Set up python "3.10"
uses: actions/setup-python@v4
with:
python-version: "3.9"
python-version: "3.10"
- name: Upgrade pip
run: |
python -m pip install --upgrade pip
Expand Down
4 changes: 3 additions & 1 deletion ebcc/ext/fci.py
Original file line number Diff line number Diff line change
Expand Up @@ -399,9 +399,11 @@ def _get_c(spins: str) -> NDArray[T]:
cn = ci[addrsi, addrsj] * signsi * signsj

# Decompress the axes
spins_full = spins + spins
spins_full = spins_full[::2] + spins_full[1::2]
shape = tuple(
space["ab".index(s)].size(char)
for char, s in zip("O" * nalph + "V" * nalph + "O" * nbeta + "V" * nbeta, spins + spins)
for char, s in zip("O" * nalph + "V" * nalph + "O" * nbeta + "V" * nbeta, spins_full)
)
subscript = "i" * nalph + "a" * nalph + "j" * nbeta + "b" * nbeta
cn = util.decompress_axes(subscript, cn, shape=shape)
Expand Down
2 changes: 1 addition & 1 deletion ebcc/util/einsumfunc.py
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ def einsum(
# If it's a chain of contractions, use the path optimizer
args = list(args)
path_kwargs = dict(optimize=optimize, einsum_call=True)
contractions = np.einsum_path(subscript, *args, **path_kwargs)[1]
contractions = np.einsum_path(subscript, *args, **path_kwargs)[1] # type: ignore[arg-type]
for contraction in contractions:
inds, idx_rm, einsum_str, remain = list(contraction[:4])
contraction_args = [args.pop(x) for x in inds] # type: ignore
Expand Down
Loading