Skip to content

typo: node -> infoset in _resolve_infoset#535

Merged
rahulsavani merged 114 commits intomaint16_2from
bug_fix_error_report_resolve_infoset
Jul 17, 2025
Merged

typo: node -> infoset in _resolve_infoset#535
rahulsavani merged 114 commits intomaint16_2from
bug_fix_error_report_resolve_infoset

Conversation

@rahulsavani
Copy link
Copy Markdown
Member

No description provided.

tturocy and others added 30 commits April 16, 2024 13:15
This refactors the build of the pygambit extension to create more granular libraries of the C++ code,
with the aim of reducing unnecessary re-builds when changes are made.
This adds maximum-likelihood estimation of agent logit QRE, in parallel to
the methods for strategic logit QRE.

Function names for estimation for the strategic version have been modified to
give a parallel naming scheme for both.
This is a substantial refactoring and cleanup of path-following and the
interface to QRE tracing.

The only new functionality is to implement the ability to stop at an interior
local maximiser when fitting QRE.

Otherwise, other changes are internal to simplify calling the various
QRE-related routines and separate concerns (e.g. formatting/printing is no longer
part of the QRE tracer itself but properly delegated to a
provided observer function if that is desired).
Bumps [jidicula/clang-format-action](https://github.com/jidicula/clang-format-action) from 4.11.0 to 4.12.0.
- [Release notes](https://github.com/jidicula/clang-format-action/releases)
- [Commits](jidicula/clang-format-action@v4.11.0...v4.12.0)

---
updated-dependencies:
- dependency-name: jidicula/clang-format-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
# Conflicts:
#	ChangeLog
Bumps [jidicula/clang-format-action](https://github.com/jidicula/clang-format-action) from 4.12.0 to 4.13.0.
- [Release notes](https://github.com/jidicula/clang-format-action/releases)
- [Commits](jidicula/clang-format-action@v4.12.0...v4.13.0)

---
updated-dependencies:
- dependency-name: jidicula/clang-format-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
* Bump actions/upload-artifact from 3 to 4

Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 3 to 4.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](actions/upload-artifact@v3...v4)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update action for building executables to upload-artifact@v4

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ted Turocy <ted.turocy@gmail.com>
* In estimating using the empirical payoff approach:
  * Return the estimated strategy profiles instead of a list of probabilities.
  * Improve the calculation of log-probabilities internally for better numerical performance, especially with small probabilities.

* In estimating using the equilibrium correspondence, expose stepsize control parameters in parallel to other correspondence-based methods.
…ltiple lambda values in the same invocation.

Closes #332.
* Simplify and rationalize naming of various functions to work with QRE correspondence
* Move functions other than logit_solve into the qre module.
* Added an appropriate section to the user guide summarizing QRE facilities.
This cleans up the implementations of the enumeration of possible Nash subsupports:

* The principal enumeration methods are extracted from enumpoly into their own directory.
* Unused or obsolete code has been removed, and some aspects of the implementation have been
  refactored for simplification.
* Enumeration for the strategic game has been experimentally exposed in pygambit.
* Refactors and modernises the internal implementaton of enumpoly
  for strategic games
* The heuristic-search version of enumpoly now uses the same per-support
  solver as the full enumeration
This drops support for Python 3.8.  In addition,
* Updates pre-commit actions
* Updates Python style for 3.9/3.10 now that 3.8 is not supported.
# Conflicts:
#	.pre-commit-config.yaml
Exports the reduced strategic representation of a game as a collection
of numpy arrays.

Closes #461.
This is a substantial reworking of the implementation of the sequence form concept
currently inside enumpoly.  This significantly simplifies the implementation
through a combination of better organisation and the use of
modern C++ features which did not exist when this implementation was
first done.

In due course a more polished version of this should become part of the
game-representation library.  This is progress towards that, but is not
yet fully stabilised.
This builds on previous work to bring the implementation of enumpoly on
extensive forms (via the sequence form) up-to-date.

This is a substantial refactoring that should improve the readability and
maintainability of these routines.

Further, the `GameSequenceForm` class has now moved towards being
ready to move to be part of the game representation library, which the goal
is to do in due course.
This does some cleanup and updating of behavextend.  This involves no
functionality changes, but removes unneeded/duplicate code,
and uses modern features like STL containers and range-based
for-loops where it is straightforward to do so.

This is not a complete modernisation as there are a few places where
modernisation is not just a trivial reworking.

In addition, it is not at all clear that these functions are necessarily fully correct,
or that the task they are solving could not be handled more easily!
This reimplements our support enumeration algorithm for strategic games,
using the approach proposed by Porter, Nudelman and Shoham (2004).
An experimental version of this had been previously included, written by
Litao Wei.
This version is re-built from the ground up as a replacement.
Further, we now use this approach as the approach for generating supports,
and have removed the old method entirely, as there is no real
benefit to the way we used to do it over what PNS propose.
This implements the stopAfter argument to enumpoly for both strategic
and extensive games, and makes it available in the
command-line tool and in pygambit.
Parsing of .nfg files has heretofore been somewhat tolerant.  If too many
payoffs or outcomes were given, extra ones were ignored silently;
if not enough were given, the missing ones were set to zero.

With this, checks are now done to ensure the correct number of outcomes or payoffs (as appropriate) are
provided.

Closes #119.
This does some general cleanups of routines to read and write savefiles:

* Creates a standardised ReadXXXFile/WriteXXXFile set of functions.
* Uses iterators to make the code, specifically the writing code, more generic.
* Removes uses of Gambit containers (and manually-managed linked lists!) in favour of STL equivalents.
This extends `enumpoly_solve` with the option to use `PHCpack` [1]_
to solve the systems of polynomial equations.

Closes #165.

.. [1] https://homepages.math.uic.edu/~jan/PHCpack/phcpack.html
tturocy and others added 20 commits April 15, 2025 13:29
Improve organisation of code in core/:
* Remove header dependency on game classes
* Update file paths in copyright notice
* Update #include guards to match file paths
Adds an internal count of the number of nodes in a game tree, rather
than counting nodes explicitly when asked.

Correspondingly, in Python, `nodes` is now a member (returning a shim
object) rather than a function.
* Eliminates derived `GameTreeInfosetRep` and `GameTreeNodeRep` classes.
* Moves operations which make strucutral changes to game trees
  to `GameTreeRep` rather than individual object classes.
This implements a new template class, ElementCollection, which represents
a collection of objects in a game.  This handles efficient access
and iteration over game objects without the need to allocate a new container.

Closes #516
This provides computation of the set of plays (terminal nodes) consistent with
passing through a specified node, information set, or action:
* `GameRep.GetPlays()` in C++
* Properties `Node.plays`, `Infoset.plays`, `Action,plays` in Python.

Closes #517.
This provides an interface to the mapping from strategy to actions in an extensive game:
* `GameStrategyRep::GetAction(GameInfoset)` in C++
* `Strategy.action(Infoset)` in Python`
This implements a Nodes collection class in a game, representing the
set of all nodes in the game tree (if defined).

The default iteration of the set of nodes is defined as depth-first traversal.

Closes #530.
@rahulsavani rahulsavani requested a review from tturocy July 14, 2025 10:00
@tturocy tturocy changed the base branch from master to maint16_2 July 14, 2025 14:13
@tturocy tturocy changed the base branch from maint16_2 to master July 14, 2025 14:13
@tturocy
Copy link
Copy Markdown
Member

tturocy commented Jul 14, 2025

This has been a bug since 16.2, so we should do the PR against maint16_2.

@tturocy tturocy changed the base branch from master to maint16_2 July 14, 2025 14:15
@tturocy tturocy changed the base branch from maint16_2 to master July 14, 2025 14:15
Copy link
Copy Markdown
Member

@tturocy tturocy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fine, but we need to have this against the branch maint16_2 instead of master.

@rahulsavani rahulsavani changed the base branch from master to maint16_2 July 17, 2025 18:22
@rahulsavani rahulsavani merged commit 078af41 into maint16_2 Jul 17, 2025
23 of 25 checks passed
@rahulsavani rahulsavani deleted the bug_fix_error_report_resolve_infoset branch November 18, 2025 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants