Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
114 commits
Select commit Hold shift + click to select a range
777523b
Refactor build of C++ for pygambit extension.
tturocy Apr 16, 2024
8c56f2e
Implement estimation of agent LQRE in pygambit.
tturocy Apr 11, 2024
5708d2a
Refactor implementation of path-following and QRE.
tturocy May 16, 2024
6735937
Bump jidicula/clang-format-action from 4.11.0 to 4.12.0
dependabot[bot] May 20, 2024
af40bc3
Merge branch 'maint16_2'
tturocy May 28, 2024
2a3fec6
Bump jidicula/clang-format-action from 4.12.0 to 4.13.0
dependabot[bot] May 27, 2024
7b1181f
Merge remote-tracking branch 'origin/master'
tturocy May 28, 2024
6675a5f
Bump actions/upload-artifact from 3 to 4 (#424)
dependabot[bot] May 28, 2024
0a53b0b
Improvements to QRE estimation operations.
tturocy May 28, 2024
1c38cb6
Extend ability to find QRE at specified lambda to allow specifying mu…
tturocy Jun 7, 2024
86a14c9
Standardization of QRE computation interface:
tturocy Jun 12, 2024
ecb272f
Merge branch 'maint16_2'
tturocy Jul 19, 2024
768879f
Clean up implementation of enumeration of possible Nash supports
tturocy Nov 8, 2023
6784a8e
This exposes enumpoly in pygambit for the first time.
tturocy Jun 26, 2024
b0eaf78
Dropped support for Python 3.8.
tturocy Jul 19, 2024
cd80351
Merge branch 'maint16_2'
tturocy Aug 20, 2024
cc7c97e
Merge branch 'maint16_2'
tturocy Aug 20, 2024
195829c
Add to_arrays method to Game class.
tturocy Aug 20, 2024
32f5190
Merge branch 'd-kad-add-to-arrays-function'
tturocy Aug 30, 2024
737dfe5
Rework sequence form implementation in enumpoly.
tturocy Jul 19, 2024
c2c77ed
Modernise further the implementation of enumpoly on sequence forms
tturocy Sep 18, 2024
d28a606
Add regret-based acceptance criterion to enumpoly.
tturocy Sep 20, 2024
c64a3ba
Debridement and modernisation of behavextend
tturocy Sep 20, 2024
34d4a56
Reimplement PNS support enumeration algorithm
tturocy Sep 25, 2024
b8383ec
Add stop_after argument to enumpoly
tturocy Oct 3, 2024
b0c3583
Enforce expected number of outcomes or payoffs in .nfg files.
tturocy Oct 4, 2024
aa45a8c
Merge branch 'maint16_2'
tturocy Oct 4, 2024
ad47d54
Validate `first_step` and `max_accel` parameters values in `logit_sol…
lusimeon Jun 19, 2024
cbd942f
Modernise and refactor reading and writing of savefiles.
tturocy Oct 9, 2024
d7d6c0f
Implement PHCpack-based backend for solving polynomial systems.
tturocy Oct 16, 2024
1d5c3c4
Remove integrated lrslib and call lrsnash as external tool.
tturocy Oct 18, 2024
008b7e8
Modernise and simplify StrategySupportProfile implementation.
tturocy Oct 23, 2024
4cfd909
Create concept of StrategyContingencies.
tturocy Oct 31, 2024
c9a7f8c
Use a map to point to strategy probabilities in MixedStrategyProfileRep.
tturocy Nov 7, 2024
25742d2
Separate builds for MacOS 13 and 14, 14 uses the M1-based runner.
tturocy Nov 8, 2024
a86c21c
Refactor and modernise behavior support and behavior contingency iter…
tturocy Nov 7, 2024
bca6be3
Refactor solve-by-subgames implementation.
tturocy Nov 20, 2024
c524945
Internal improvements in logit-solve for extensive games.
tturocy Nov 21, 2024
a6fcf5a
Remove some unneeded or unused classes and functions.
tturocy Nov 21, 2024
3eb9558
Better comments nim.efg/nim7.efg and entry in samples.rst
rahulsavani Nov 19, 2024
c74d40c
Move simplified PVector to simplicial subdivision
tturocy Nov 22, 2024
f06caa3
Modernisation of LU decomposition
tturocy Dec 2, 2024
5145063
Merge branch 'maint16_2' into master
tturocy Dec 9, 2024
a65b120
Remove support for writing GTE XML files.
tturocy Dec 9, 2024
f6ff878
Modernisation of parts of VertexEnumerator and LPTableau
tturocy Dec 3, 2024
b96c025
Complete migration of tests from unittest to pytest style.
tturocy Dec 9, 2024
15d17d7
Bump jidicula/clang-format-action from 4.13.0 to 4.14.0
dependabot[bot] Dec 2, 2024
e85f8d8
Migrate List to be a thin wrapper of std::list
tturocy Dec 10, 2024
3ad9327
Move index_pair to be a type within gPolyList, use std::pair.
tturocy Dec 12, 2024
9cfe468
Remove unused polynomial-related code
tturocy Dec 12, 2024
f2cf68b
Refactor polynomial-related classes formerly in prepoly.h
tturocy Dec 12, 2024
77e73de
Simplify and organise implementation of gPoly
tturocy Dec 13, 2024
c76d074
Update wxWidgets to 3.2 in ubuntu build
tturocy Dec 17, 2024
4502065
Modernisation of Vector implementation
tturocy Dec 18, 2024
45d8d10
Rewrite some Array operations to be more std::vector-like
tturocy Dec 17, 2024
c066dbc
Make Array as similar to std::vector as possible.
tturocy Dec 23, 2024
dff978e
Simplify and modernise implementation of interval and rectangle.
tturocy Dec 23, 2024
8fbf142
Tidying and organisation of enumpoly
tturocy Jan 2, 2025
e978161
Merge branch 'maint16_2' into merge_16_2
tturocy Jan 7, 2025
ac2ab5d
Implementing functions for reading and writing game files of speciali…
d-kad Nov 9, 2024
1e40753
Revise tests to use new de-seralisation functions instead of deprecat…
tturocy Jan 9, 2025
8423c07
Fix regression in Array
tturocy Jan 9, 2025
c1a222c
Add enumpoly back to GUI
tturocy Jan 9, 2025
010dfb9
Correct handling of non-invertible matrix in Newton's step in enumpoly
tturocy Jan 10, 2025
0319f70
Update version to 16.3.0.
tturocy Jan 13, 2025
479c814
This makes a few updates/modernisations to the Cython implementation
tturocy Jan 14, 2025
9b916be
Remove deprecated reading/writing functions
tturocy Jan 15, 2025
105dbac
Remove class structure for Nash equilibrium algorithms
tturocy Jan 14, 2025
6240732
Add a static build of OSX graphical interface
EdwinB12 Jan 13, 2025
64ecf8a
Updates to PureStrategyProfile
tturocy Jan 29, 2025
d27e16d
Some cleanup of linear algebra sublibrary
tturocy Feb 3, 2025
5295d31
Fix to writing correctly the serialised game to a named file.
tturocy Mar 20, 2025
cd813a0
Rewrite some Game internals to use STL algorithms and iterators inste…
tturocy Mar 20, 2025
41dc9ee
Remove GetAction(int) from Game as part of deprecating access-by-inde…
tturocy Mar 21, 2025
c8c2046
Remove GetActionProb(int) from GameInfoset.
tturocy Mar 21, 2025
70ee889
Bump jidicula/clang-format-action from 4.14.0 to 4.15.0
dependabot[bot] Mar 24, 2025
6ef5d57
Rationalise implementation of outcome objects
tturocy Mar 24, 2025
c308a1b
Add missing MixedBehaviorProfile.infoset_regret and MixedBehaviorProf…
tturocy Mar 25, 2025
02cd061
Regression fix for serialising game when filename is specified.
tturocy Mar 28, 2025
ef6e67b
Regression fix for premature invalidation of object.
tturocy Mar 27, 2025
f038c28
Merge branch 'maint16_3'
tturocy Mar 28, 2025
a65784d
Change GamePlayerRep::m_infosets from Array to std::vector.
d-kad Mar 28, 2025
b5897f9
Merge branch 'maint16_2' into maint16_3
tturocy Mar 28, 2025
107eeaa
Merge branch 'maint16_3'
tturocy Mar 28, 2025
a9fbcf1
Modernisation of some MixedStrategyProfile-related operations.
tturocy Mar 28, 2025
8f93587
Change GameTreeInfosetRep::m_members from Array to std::vector.
d-kad Mar 29, 2025
8994b3a
Separate implementation of player-specific and overall min/max payoffs.
tturocy Mar 31, 2025
6790db5
Improvements to clang-tidy checks
tturocy Apr 1, 2025
6ccbdeb
Remove mentions in help strings of command-line options which are not…
tturocy Apr 2, 2025
0bb6ddf
Merge branch 'maint16_2' into maint16_3
tturocy Apr 9, 2025
e487cb4
Merge branch 'maint16_3'
tturocy Apr 9, 2025
7381f3e
Maintenance and update to project configuration and metadata
tturocy Apr 9, 2025
152b17b
Address some common compiler warnings.
tturocy Apr 9, 2025
70690db
Migrate creation and deletion of strategies to `GameRep`
tturocy Apr 15, 2025
9591cd4
Rationalise organisation of core directory
tturocy Apr 15, 2025
0a04bab
Implement tracking of node count of game trees.
d-kad Mar 29, 2025
58f66f5
Make players a data member of the base game, and STLify.
d-kad Apr 2, 2025
3e5cc45
Simplification and modernisation in game representation
tturocy Apr 15, 2025
8d1989d
Make GameRep::BuildComputedValues logically const
tturocy Apr 23, 2025
7ab1937
change m_outcomes from Array to std::vector and move them to GameRep
d-kad Apr 26, 2025
feec4ec
Fix bug in m_numNodes counter when doing operations involving deletion
d-kad May 2, 2025
a4b4936
add m_numNonterminalNodes field to GameRep
d-kad May 2, 2025
ca9256b
Remove GameNodeRep::GetChild(int) and implement children as a std::ve…
tturocy May 1, 2025
c17c911
In `GameTableRep`, store results table as `std::vector` instead of `A…
tturocy May 6, 2025
488290c
Use std::vector in NewTable
tturocy May 6, 2025
73abea1
Change GameInfosetRep::m_actions to std::vector
d-kad May 2, 2025
53c5e5c
Change GameInfosetRep::m_probs from Gambit::Array to std::vector
d-kad May 6, 2025
5b7788a
Convert GamePlayerRep::m_strategies from Array to std::vector
tturocy May 12, 2025
229f495
Implement collection classes for games.
tturocy May 1, 2025
7df3d34
Implement plays consistent with a node, information set, or action
d-kad May 9, 2025
918cf55
Expose access to action map for a strategy
tturocy Jan 28, 2025
b017e1a
Tests for the creation of the reduced strategic form from an extensiv…
rahulsavani Jun 11, 2025
89cbddc
Implement Nodes collection for games.
d-kad Jun 21, 2025
9ead06c
typo: node -> infoset in _resolve_infoset
rahulsavani Jul 14, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
5 changes: 1 addition & 4 deletions .clang-tidy
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,12 @@ Checks: |
-modernize-avoid-c-arrays,
-modernize-pass-by-value,
-modernize-use-nodiscard,
-modernize-concat-nested-namespaces,
cppcoreguidelines-pro-type-cstyle-cast,
cppcoreguidelines-pro-type-member-init,
cppcoreguidelines-prefer-member-initializer,
misc-const-correctness
WarningsAsErrors: '*'
# Don't bother with wxWidgets headers
HeaderFilterRegex: '^((?!labenski).)*$'
AnalyzeTemporaryDtors: false
HeaderFilterRegex: '.*'
FormatStyle: none
User: arbiter
CheckOptions:
Expand Down
15 changes: 15 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"image": "mcr.microsoft.com/devcontainers/base:ubuntu-24.04",
"features": {
"ghcr.io/devcontainers/features/python:1": {
"installTools": true,
"version": "3.11"
},
"ghcr.io/devcontainers-contrib/features/gdbgui:2": {
"version": "latest"
},
"ghcr.io/rocker-org/devcontainer-features/apt-packages:1": {
"packages": "automake,autoconf,gdb"
}
}
}
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Run clang-format style check for C/C++
uses: jidicula/clang-format-action@v4.11.0
uses: jidicula/clang-format-action@v4.15.0
with:
clang-format-version: '17'
check-path: 'src'
Expand Down
37 changes: 37 additions & 0 deletions .github/workflows/osxbinary.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: MacOS static GUI binary

on:
push:
tags:
- 'v*'
schedule:
- cron: '0 6 * * 4'

jobs:
macos-13:
runs-on: macos-13
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: |
brew install automake autoconf
curl -L -O https://github.com/wxWidgets/wxWidgets/releases/download/v3.2.6/wxWidgets-3.2.6.tar.bz2
tar xjf wxWidgets-3.2.6.tar.bz2
cd wxWidgets-3.2.6
mkdir build-release
cd build-release
../configure --disable-shared --disable-sys-libs
make -j4
sudo make install
- run: aclocal
- run: automake --add-missing
- run: autoconf
- run: ./configure
- run: make
- run: sudo make install
- run: make osx-dmg
- uses: actions/upload-artifact@v4
with:
name: artifact-osx-13
path: "*.dmg"
56 changes: 51 additions & 5 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
strategy:
matrix:
python-version: ['3.8', '3.12']
python-version: ['3.9', '3.13']

steps:
- uses: actions/checkout@v4
Expand All @@ -21,23 +21,69 @@ jobs:
- name: Set up dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools cython pytest wheel lxml numpy scipy
pip install setuptools build cython pytest pytest-skip-slow wheel lxml numpy scipy
- name: Build source distribution
run:
python setup.py sdist
python -m build
- name: Build from source distribution
run: |
cd dist
pip install -v pygambit*.tar.gz
- name: Run tests
run: pytest

macos-13:
runs-on: macos-13
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
strategy:
matrix:
python-version: ['3.13']

steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Set up dependencies
run: |
python -m pip install --upgrade pip
pip install cython pytest pytest-skip-slow wheel lxml numpy scipy
- name: Build extension
run: |
python -m pip install -v .
- name: Run tests
run: pytest

macos-14:
runs-on: macos-14
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
strategy:
matrix:
python-version: ['3.13']

steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Set up dependencies
run: |
python -m pip install --upgrade pip
pip install cython pytest pytest-skip-slow wheel lxml numpy scipy
- name: Build extension
run: |
python -m pip install -v .
- name: Run tests
run: pytest

windows:
runs-on: windows-latest
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
strategy:
matrix:
python-version: ['3.12']
python-version: ['3.13']

steps:
- uses: actions/checkout@v4
Expand All @@ -48,7 +94,7 @@ jobs:
- name: Set up dependencies
run: |
python -m pip install --upgrade pip
pip install cython pytest wheel lxml numpy scipy
pip install cython pytest pytest-skip-slow wheel lxml numpy scipy
- name: Build extension
run: |
python -m pip install -v .
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tools.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
- run: make osx-dmg
- uses: actions/upload-artifact@v4
with:
name: artifact-macos
name: artifact-osx
path: "*.dmg"

windows:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,4 @@ missing
gambit
.python-version
dist
.venv
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
rev: v4.6.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
Expand All @@ -11,11 +11,11 @@ repos:
hooks:
- id: ruff
- repo: https://github.com/pycqa/flake8
rev: 7.0.0
rev: 7.1.0
hooks:
- id: flake8
- repo: https://github.com/MarcoGorelli/cython-lint
rev: v0.16.0
rev: v0.16.2
hooks:
- id: cython-lint
- id: double-quote-cython-strings
Expand Down
69 changes: 69 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,5 +1,74 @@
# Changelog

## [16.4.0] - unreleased

### General
- Officially added support for Python 3.13.

### Removed
- The deprecated functions `Game.read_game`, `Game.parse_game` and `Game.write` functions have
been removed as planned. (#357)

### Added
- Implement `GetPlays()` (C++) and `get_plays` (Python) to compute the set of terminal nodes consistent
with a node, information set, or action (#517)
- Implement `GameStrategyRep::GetAction` (C++) and `Strategy.action` (Python) retrieving the action
prescribed by a strategy at an information set
- Tests for creation of the reduced strategic form from an extensive-form game (currently only
for games with perfect recall)
- Implement `Nodes` collection as a member of `GameRep`, including a C++ iterator that
returns nodes in depth-first traversal order (#530)


## [16.3.1] - unreleased

### Fixed
- Corrected a regression in which information sets were prematurely invalidated (and therefore
`delete this` called on them) when removing the last node from an information set.


## [16.3.0] - 2025-01-13

### General
- Dropped support for Python 3.8.

### Added
- Implemented maximum-likelihood estimation for agent logit QRE, to parallel existing support
for strategic logit QRE. Strategic logit QRE function names have been modified to provide
parallel naming. Estimation using the correspondence now supports an option to stop at the
first interior local maximizer found (if one exists).
- Maximum-likelihood estimation for logit QRE using empirical payoffs has an improved internal
calculation of log-likelihood, and returns the estimated profile instead of just a list of
probabilities.
- Reorganized naming conventions in pygambit for functions for computing QRE in both strategic
and agent versions, and added a corresponding section in the user guide.
- `enumpoly_solve` has been returned to being fully supported from temporarily being experimental;
now available in `pygambit`.
- `enumpoly_solve` for strategic games now uses the Porter, Nudelman, and Shoham (2004) ordering
of supports to search.
- `to_arrays` converts a `Game` to a list of `numpy` arrays containing its reduced strategic form.
(#461)
- Integrated support (in Python) for using `PHCpack` to solve systems of polynomial equations in
`enumpoly_solve` based on an implementation formerly in the `contrib` section of the
repository. (#165)
- New format-specific functions `pygambit.read_*` and `pygambit.Game.to_*` functions have been
added to (de-)serialise games. The existing `Game.read_game` and `Game.write` functions have
been deprecated and will be removed in 16.4. (#357)

### Changed
- The built-in implementation of lrslib (dating from 2016) has been removed. Instead, access to
lrsnash is provided as an external tool via the `enummixed_solve` function, in parallel to
PHCpack for `enumpoly_solve`.

### Fixed
- When parsing .nfg files, check that the number of outcomes or payoffs is the expected number,
and raise an exception if not. (#119)

### Removed
- `Game.write()` no longer supports generation of the XML-format files for Game Theory
Explorer, as GTE no longer reads files in this format.


## [16.2.2] - unreleased

### Fixed
Expand Down
Loading
Loading