Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
Seminar-HFO
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Shashank Suhas
Seminar-HFO
Commits
d0ae33f4
You need to sign in or sign up before continuing.
Commit
d0ae33f4
authored
Jul 16, 2017
by
drallensmith
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into mark_player_better - bring in updates, avoid rebase
parents
944de933
8426776e
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
14 deletions
+19
-14
.gitignore
.gitignore
+1
-0
example/hand_coded_defense_agent
example/hand_coded_defense_agent
+0
-0
example/hand_coded_defense_agent.cpp
example/hand_coded_defense_agent.cpp
+18
-11
example/make_hand_coded_defense_agent_executable.sh
example/make_hand_coded_defense_agent_executable.sh
+0
-3
No files found.
.gitignore
View file @
d0ae33f4
...
...
@@ -73,6 +73,7 @@ example/mid_level_move_agent
example/mid_level_kick_agent
example/mid_level_dribble_agent
example/communication_agent
example/hand_coded_defense_agent
# Dependency directories
librcsc-prefix/
...
...
example/hand_coded_defense_agent
deleted
100755 → 0
View file @
944de933
File deleted
example/hand_coded_defense_agent.cpp
View file @
d0ae33f4
...
...
@@ -208,7 +208,8 @@ int main(int argc, char** argv) {
HFOEnvironment
hfo
;
int
random
=
0
;
double
numGoals
=
0
;
double
numEpisodes
=
5000
;
int
numEpisodes
=
5000
;
double
actualNumEpisodes
=
0
;
// Connect to the server and request high-level feature set. See
// manual for more information on feature sets.
hfo
.
connectToServer
(
features
,
config_dir
,
port
,
server_addr
,
...
...
@@ -233,10 +234,10 @@ int main(int argc, char** argv) {
string
s
=
hfo
::
ActionToString
(
a
.
action
)
+
" "
+
to_string
(
a
.
param
)
+
"
\n
"
;
// std::cout << s;
}
else
{
std
::
cout
<<
"Rand
m"
;
std
::
cout
<<
"Rando
m"
;
action_t
a
=
get_random_high_lv_action
();
if
(
a
==
hfo
::
MARK_PLAYER
)
{
hfo
.
act
(
NOOP
);
hfo
.
act
(
NOOP
);
// why not MOVE?
}
else
{
hfo
.
act
(
a
);
}
...
...
@@ -249,8 +250,14 @@ int main(int argc, char** argv) {
// Check what the outcome of the episode was
cout
<<
"Episode "
<<
episode
<<
" ended with status: "
<<
StatusToString
(
status
)
<<
std
::
endl
;
if
(
status
==
SERVER_DOWN
)
{
break
;
}
else
{
actualNumEpisodes
++
;
}
}
double
cost
=
numGoals
/
n
umEpisodes
;
double
cost
=
numGoals
/
actualN
umEpisodes
;
hfo
.
act
(
QUIT
);
//write_cost(cost);
};
...
...
example/make_hand_coded_defense_agent_executable.sh
deleted
100755 → 0
View file @
944de933
# Run this file to create an executable of hand_coded_defense_agent.cpp
g++
-c
hand_coded_defense_agent.cpp
-I
../src/
-std
=
c++0x
-pthread
g++
-L
../lib/ hand_coded_defense_agent.o
-lhfo
-pthread
-o
hand_coded_defense_agent
-Wl
,-rpath,../lib
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment