graph-games-proto 0.3.1932__py3-none-any.whl → 0.3.1935__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- graph_games_proto/fns.py +1 -7
- {graph_games_proto-0.3.1932.dist-info → graph_games_proto-0.3.1935.dist-info}/METADATA +1 -1
- {graph_games_proto-0.3.1932.dist-info → graph_games_proto-0.3.1935.dist-info}/RECORD +5 -5
- {graph_games_proto-0.3.1932.dist-info → graph_games_proto-0.3.1935.dist-info}/WHEEL +0 -0
- {graph_games_proto-0.3.1932.dist-info → graph_games_proto-0.3.1935.dist-info}/top_level.txt +0 -0
graph_games_proto/fns.py
CHANGED
@@ -16,7 +16,7 @@ from itertools import combinations as itertools_combinations, chain
|
|
16
16
|
from collections import deque
|
17
17
|
|
18
18
|
DEFAULT_ALLOTTED_SECONDS = 12
|
19
|
-
INITIAL_ALLOTTED_SECONDS =
|
19
|
+
INITIAL_ALLOTTED_SECONDS = 22
|
20
20
|
|
21
21
|
class NoAction(PClass):
|
22
22
|
pass
|
@@ -2037,7 +2037,6 @@ class State(PClass):
|
|
2037
2037
|
nodes = field(type=list) # List[Node]
|
2038
2038
|
nodeuuid2idx = field(type=dict) # Dict[str, int]
|
2039
2039
|
edges = field(type=list) # List[BiEdge]
|
2040
|
-
edgeuuid2idx = field(type=dict) # Dict[str, int]
|
2041
2040
|
edgetuple2uuid = field(type=dict) # Dict[Tuple[int, int], str]
|
2042
2041
|
regions = field(type=list) # List[Region]
|
2043
2042
|
legal_actions_3 = field(type=list) # List[LegalAction]
|
@@ -2066,7 +2065,6 @@ class State(PClass):
|
|
2066
2065
|
"nodes": [node.__todict__() for node in self.nodes],
|
2067
2066
|
"nodeuuid2idx": self.nodeuuid2idx,
|
2068
2067
|
"edges": [edge.__todict__() for edge in self.edges],
|
2069
|
-
"edgeuuid2idx": self.edgeuuid2idx,
|
2070
2068
|
"edgetuple2uuid": [{"k": list(k), "v": v} for k, v in self.edgetuple2uuid.items()],
|
2071
2069
|
"regions": [region.__todict__() for region in self.regions],
|
2072
2070
|
"legal_actions_3": [x.__todict__() for x in self.legal_actions_3],
|
@@ -2097,7 +2095,6 @@ class State(PClass):
|
|
2097
2095
|
nodes=[Node.__fromdict__(n) for n in d["nodes"]],
|
2098
2096
|
nodeuuid2idx=d["nodeuuid2idx"],
|
2099
2097
|
edges=[BiEdge.__fromdict__(e) for e in d["edges"]],
|
2100
|
-
edgeuuid2idx=d["edgeuuid2idx"],
|
2101
2098
|
edgetuple2uuid={tuple(item["k"]): item["v"] for item in d["edgetuple2uuid"]},
|
2102
2099
|
regions=[Region.__fromdict__(r) for r in d["regions"]],
|
2103
2100
|
legal_actions_3=[LegalAction.__fromdict__(x) for x in d["legal_actions_3"]],
|
@@ -2606,7 +2603,6 @@ def getinitialstate(game_config):
|
|
2606
2603
|
|
2607
2604
|
nodeuuid2idx = {node.uuid: idx for idx, node in enumerate(board_config.points)}
|
2608
2605
|
edges = get_edges(rng, board_config, nodeuuid2idx)
|
2609
|
-
edgeuuid2idx = {edge.uuid: idx for idx, edge in enumerate(edges)}
|
2610
2606
|
edgetuple2uuid = {}
|
2611
2607
|
for edge in edges:
|
2612
2608
|
node_1_idx = nodeuuid2idx[edge.node_1_uuid]
|
@@ -2662,7 +2658,6 @@ def getinitialstate(game_config):
|
|
2662
2658
|
nodes = nodes,
|
2663
2659
|
nodeuuid2idx = nodeuuid2idx,
|
2664
2660
|
edges = edges,
|
2665
|
-
edgeuuid2idx = edgeuuid2idx,
|
2666
2661
|
edgetuple2uuid = edgetuple2uuid,
|
2667
2662
|
regions = get_regions(board_config),
|
2668
2663
|
legal_actions_3=[],
|
@@ -4076,7 +4071,6 @@ def init_state(kernel):
|
|
4076
4071
|
is_terminal=False,
|
4077
4072
|
idx2path=kernel.idx2path,
|
4078
4073
|
pieceuuid2piece=kernel.pieceuuid2piece,
|
4079
|
-
edgeuuid2idx=kernel.edgeuuid2idx,
|
4080
4074
|
carduuid2card=kernel.carduuid2card,
|
4081
4075
|
)
|
4082
4076
|
state = state.set(legal_actions_3=calc_legal_actions3(kernel))
|
@@ -1,9 +1,9 @@
|
|
1
1
|
graph_games_proto/__init__.py,sha256=_EVQR-51XehfH45XZlba1WPdx3omS3Gm1nTwrgGyn2Q,667
|
2
2
|
graph_games_proto/all_types.py,sha256=IpbwftEcHS5Ewz-saFNk0lO9FvcbuHG36odRTayCXUk,54911
|
3
|
-
graph_games_proto/fns.py,sha256=
|
3
|
+
graph_games_proto/fns.py,sha256=Z1wk8lPk39U7qe84dnL749mSIcG-xiIiPKFjCG0mUGE,182031
|
4
4
|
graph_games_proto/main.py,sha256=fj2U7KcwrpZtuUhjOX5yVxY18LZvvsxDFYZ_S5mxe04,145
|
5
5
|
graph_games_proto/state.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
6
|
-
graph_games_proto-0.3.
|
7
|
-
graph_games_proto-0.3.
|
8
|
-
graph_games_proto-0.3.
|
9
|
-
graph_games_proto-0.3.
|
6
|
+
graph_games_proto-0.3.1935.dist-info/METADATA,sha256=LWnt0sLT7V7SwgFk3_hXmRXORmEu0mZQshFGugg-sTw,188
|
7
|
+
graph_games_proto-0.3.1935.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
|
8
|
+
graph_games_proto-0.3.1935.dist-info/top_level.txt,sha256=-4QSrBMf_MM4BGsr2QXBpqDx8c8k_OPnzGyFjqjakes,18
|
9
|
+
graph_games_proto-0.3.1935.dist-info/RECORD,,
|
File without changes
|
File without changes
|