Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update env #2

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 9 additions & 7 deletions environment.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
name: procgen
channels:
- conda-forge

- nodefaults
dependencies:
- python=3.7.3
- python
# https://www.anaconda.com/utilizing-the-new-compilers-in-anaconda-distribution-5/
- c-compiler=1.3.0
- c-compiler
- cmake=3.21.3
- qt=5.12.5 # conda-forge does not have 5.13.2 available
- qt=5.15.8
- filelock
- numpy
- gym
- glfw
- pip
- pip:
- gym3==0.3.3
- numpy==1.17.2
- gym==0.15.3
- filelock==3.0.10
2 changes: 1 addition & 1 deletion procgen/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -75,4 +75,4 @@ add_library(env
# find libenv.h header
target_include_directories(env PUBLIC ${LIBENV_DIR})

target_link_libraries(env Qt5::Gui)
target_link_libraries(env Qt5::Gui)
2 changes: 0 additions & 2 deletions procgen/src/games/chaser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,6 @@ class ChaserGame : public BasicAbstractGame {
void game_step() override {
BasicAbstractGame::game_step();

int num_orbs = 0;
int num_enemies = 0;

float default_enemy_speed = .5;
Expand All @@ -303,7 +302,6 @@ class ChaserGame : public BasicAbstractGame {
auto ent = entities[j];

if (ent->type == ORB) {
num_orbs++;
} else if (ent->type == ENEMY_EGG) {
num_enemies++;
ent->health -= 1;
Expand Down
2 changes: 1 addition & 1 deletion procgen/src/games/starpilot.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ class StarPilotGame : public BasicAbstractGame {

bool can_spawn_left = options.distribution_mode != EasyMode;

for (int i = 0; t <= SHOOTER_WIN_TIME; i++) {
while (t <= SHOOTER_WIN_TIME) {
int group_size = 1;
float start_weight = rand_gen.rand01() * total_prob_weight;
float curr_weight = start_weight;
Expand Down