Skip to content

Commit 4a41b5a

Browse files
committed
0.1.4 - ConnectX Release
1 parent 0386e96 commit 4a41b5a

File tree

11 files changed

+2879
-13
lines changed

11 files changed

+2879
-13
lines changed

.gcloudignore

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# This file specifies files that are *not* uploaded to Google Cloud Platform
2+
# using gcloud. It follows the same syntax as .gitignore, with the addition of
3+
# "#!include" directives (which insert the entries of the given .gitignore-style
4+
# file at that point).
5+
#
6+
# For more information, run:
7+
# $ gcloud topic gcloudignore
8+
#
9+
.gcloudignore
10+
# If you would like to upload your .git directory, .gitignore file or files
11+
# from your .gitignore file, remove the corresponding line
12+
# below:
13+
.git
14+
.gitignore
15+
16+
node_modules
17+
#!include:.gitignore

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# [<img src="https://kaggle.com/static/images/site-logo.png" height="50" style="margin-bottom:-15px" />](https://kaggle.com) Environments
22

3-
> **ALPHA RELEASE** - Breaking changes may be introduced!
4-
53
```bash
64
pip install kaggle-environments
75
```
86

7+
**BETA RELEASE** - Breaking changes may be introduced!
8+
99
## TLDR;
1010

1111
```python

kaggle_environments/core.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -272,22 +272,22 @@ def train(self, agents=[]):
272272
Example:
273273
env = make("tictactoe")
274274
# Training agent in first position (player 1) against the default random agent.
275-
reset, step = env.train([None, "random"])
275+
trainer = env.train([None, "random"])
276276
277-
obs = reset()
277+
obs = trainer.reset()
278278
done = False
279279
while not done:
280280
action = 0 # Action for the agent being trained.
281-
obs, reward, done, info = step(action)
281+
obs, reward, done, info = trainer.step(action)
282282
env.render()
283283
284284
Args:
285285
agents (list): List of agents to obtain actions from while training.
286286
The agent to train (in position), should be set to "None".
287287
288288
Returns:
289-
`tuple`[0]: Reset def that reset the environment, then advances until the agents turn.
290-
`tuple`[1]: Steps using the agent action, then advance until agents turn again.
289+
`dict`.reset: Reset def that reset the environment, then advances until the agents turn.
290+
`dict`.step: Steps using the agent action, then advance until agents turn again.
291291
"""
292292
position = None
293293
for index, agent in enumerate(agents):
@@ -319,7 +319,7 @@ def step(action):
319319

320320
reset()
321321

322-
return (reset, step)
322+
return structify({"step": step, "reset": reset})
323323

324324
@property
325325
def name(self):

0 commit comments

Comments
 (0)