Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Ozan Catal
Animal Ai Env
Commits
d7bc7c40
Commit
d7bc7c40
authored
May 23, 2020
by
Benjamin
Browse files
add args to xvfb command
parent
0c8ea763
Changes
1
Hide whitespace changes
Inline
Side-by-side
animalai/animalai/envs/environment.py
View file @
d7bc7c40
...
@@ -58,7 +58,7 @@ class AnimalAIEnvironment(UnityEnvironment):
...
@@ -58,7 +58,7 @@ class AnimalAIEnvironment(UnityEnvironment):
self
.
side_channels
=
side_channels
if
side_channels
else
[]
self
.
side_channels
=
side_channels
if
side_channels
else
[]
self
.
arenas_parameters_side_channel
=
None
self
.
arenas_parameters_side_channel
=
None
self
.
use_xvfb
=
True
self
.
use_xvfb
=
True
self
.
configure_side_channels
(
self
.
side_channels
)
self
.
configure_side_channels
(
self
.
side_channels
)
super
().
__init__
(
super
().
__init__
(
...
@@ -144,13 +144,12 @@ class AnimalAIEnvironment(UnityEnvironment):
...
@@ -144,13 +144,12 @@ class AnimalAIEnvironment(UnityEnvironment):
)
from
perm
)
from
perm
else
:
else
:
docker_ls
=
(
launch_string
=
f
"exec xvfb-run --auto-servernum --server-args='-screen 0 640x480x24'"
f
"exec xvfb-run --auto-servernum --server-args='-screen 0 640x480x24'"
launch_string
+=
f
"
{
launch_string
}
{
UnityEnvironment
.
PORT_COMMAND_LINE_ARG
}
{
self
.
port
}
"
f
"
{
launch_string
}
{
UnityEnvironment
.
PORT_COMMAND_LINE_ARG
}
{
self
.
port
}
"
launch_string
+=
" "
.
join
(
args
)
)
self
.
proc1
=
subprocess
.
Popen
(
self
.
proc1
=
subprocess
.
Popen
(
docker_ls
,
launch_string
,
stdout
=
subprocess
.
PIPE
,
stdout
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
PIPE
,
shell
=
True
,
shell
=
True
,
...
...
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