Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
baselines
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Flatland
baselines
Commits
12e52a2e
Commit
12e52a2e
authored
5 years ago
by
Erik Nygren
Browse files
Options
Downloads
Patches
Plain Diff
updated sequential agent
parent
1dd88043
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
sequential_agent/run_test.py
+1
-1
1 addition, 1 deletion
sequential_agent/run_test.py
sequential_agent/simple_order_agent.py
+1
-1
1 addition, 1 deletion
sequential_agent/simple_order_agent.py
with
2 additions
and
2 deletions
sequential_agent/run_test.py
+
1
−
1
View file @
12e52a2e
...
...
@@ -66,9 +66,9 @@ for trials in range(1, n_trials + 1):
for
a
in
range
(
env
.
get_num_agents
()):
if
done
[
a
]:
acting_agent
+=
1
print
(
acting_agent
)
if
a
==
acting_agent
:
action
=
agent
.
act
(
obs
[
a
],
eps
=
0
)
print
(
action
)
else
:
action
=
4
action_dict
.
update
({
a
:
action
})
...
...
This diff is collapsed.
Click to expand it.
sequential_agent/simple_order_agent.py
+
1
−
1
View file @
12e52a2e
...
...
@@ -12,7 +12,7 @@ class OrderedAgent:
:param state: input is the observation of the agent
:return: returns an action
"""
_
,
distance
,
_
=
split_tree
(
tree
=
np
.
array
(
state
),
num_features_per_node
=
9
,
_
,
distance
,
_
=
split_tree
(
tree
=
np
.
array
(
state
),
num_features_per_node
=
11
,
current_depth
=
0
)
distance
=
distance
[
1
:]
min_dist
=
min_gt
(
distance
,
0
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment