decisionforce / pgdrive Goto Github PK
View Code? Open in Web Editor NEWPGDrive: an open-ended driving simulator with infinite scenes from procedural generation
Home Page: https://decisionforce.github.io/pgdrive/
License: Apache License 2.0
PGDrive: an open-ended driving simulator with infinite scenes from procedural generation
Home Page: https://decisionforce.github.io/pgdrive/
License: Apache License 2.0
The pre-generated maps are identical to previous version, verified in Dec 19, 2020.
Link to #14
The allowable display:
Ref:
https://docs.panda3d.org/1.10/python/programming/configuration/configuring-panda3d
https://docs.panda3d.org/1.10/python/programming/texturing/texture-compression?highlight=pandagles
If so, we can leverage more workers in RGB training!
To prevent new PR from introducing new bug, we need some unit tests to do CI
So that we can smooth the edge between sky and grassland! See: https://docs.panda3d.org/1.10/python/programming/render-attributes/fog
In that case, current save and load maps mechanism will raise error.
This is dangerous for map-generation.
pgdrive
setup.py
's description
and Readme, logo) change to PGDrive
pgdrive
(everything in code and setup.py
's name
)I need to train again for a super agent.
Professor says when using enjoy
script the FPS slows down gradually.
Quanyi has made a ResetEnv before, with the capacity to use keyboard stroke to reset the environment. I think that's good to integrate such functionalities into the default environment when using manual controlling.
We can also think of other useful commands that we wish to tell the environment, for example the maximum FPS.
The primal goal:
Use the trajectory from lidar-specified environment, to generate a new RGB-image observation trajectory.
This is the preliminary functionality, before we wish to use lidar-based agent to generate image-based trajectory for imitation learning.
To Do List:
We should not assume user's gym version!
When you set camera_height
to 800 to see the overview of the whole scenes, you will find that during reset
, the environment is reverse for a moment.
Reproduction:
camera_height
to 800Before reset (last environment):
First moment when resetting:
Third moment when resetting:
The agent driving in the scene:
To prevent PR from introducing new bugs, we need a zombie car to help us check.
Press once: force to 60
Press twice: force to realtime
env = PGDriveEnv({
"environment_num": 10000,
"traffic_density": 0.2,
"map_config": {
Map.GENERATE_METHOD: MapGenerateMethod.BIG_BLOCK_NUM,
Map.GENERATE_PARA: 7,
}
})
env = PGDriveEnv({
"environment_num": 10000,
"traffic_density": 0.5,
"map_config": {
Map.GENERATE_METHOD: MapGenerateMethod.BIG_BLOCK_NUM,
Map.GENERATE_PARA: 7,
}
})
@lqy0057 Please take a look on: add-helper branch
, pgdrive/tests/generalization_env_test/test_vehicle_num.py
This issue is for reference only. We believe this bug is fixed after #86 and #146 .
If any user find this issue again, please report to us, thanks!
Keywords: memory leak, render, rendering, pipeline, model, texture, compress, compression, break, broken, gles, Mac, platform, onscreen, window, pgdrive v0.1.0
1. Final update of README, with carefully polished languague
2. Final update of Documents
3. Upload a new expert agent
4. Check all test scripts is working (remove failed ones)
5. Check all examples scripts is working (three local-run examples, colab script should wait the publication of repo.)
Current package size is too large for installation!
@lqy0057
You should press twice "1" in order to see the box debug result.
Including:
We notice extremely large step reward.
After fixing the velocity #125 #129 , no extremely small step reward found:
Let's take a look:
current_lane = self.vehicle.lane
long_last, _ = current_lane.local_coordinates(self.vehicle.last_position)
long_now, lateral_now = current_lane.local_coordinates(self.vehicle.position)
# Suspicious!
reward = 0.0
lateral_factor = 1 - 2 * abs(lateral_now) / self.current_map.lane_width
reward += self.config["driving_reward"] * (long_now - long_last) * lateral_factor
# Suspicious!
steering_change = abs(self.vehicle.last_current_action[0][0] - self.vehicle.last_current_action[1][0])
steering_penalty = self.config["steering_penalty"] * steering_change * self.vehicle.speed / 20
reward -= steering_penalty
# Zero!
acceleration_penalty = self.config["acceleration_penalty"] * ((action[1])**2)
reward -= acceleration_penalty
# Zero!
low_speed_penalty = 0
if self.vehicle.speed < 1:
low_speed_penalty = self.config["low_speed_penalty"] # encourage car
reward -= low_speed_penalty
# Zero!
reward -= self.config["general_penalty"]
# Suspicious!
reward += self.config["speed_reward"] * (self.vehicle.speed / self.vehicle.max_speed)
The driving status label and white line framework are incorrect, when using different resolution
Can we suppress pygame message?
2020-12-20 09:58:25.610 python[17378:331264] IMKClient Stall detected, *please Report* your user scenario attaching a spindump (or sysdiagnose) that captures the problem - (imkxpc_bundleIdentifierWithReply:) block performed very slowly (5.89 secs).
Is this msg what we expected?
There are still references of ImageBuffer in pgworld class and python will not release these useless things. It's ok when we only create vehicle for once, but creating and destroying vehicle for several times will cause critical bugs due to memory leak (segment fault or other problem)
(Feel free for the agents training with lidar. This bug will not affect them
The following config can be changed and take effect in next episode:
Currently, the map seed and traffic seed are coupled in PGDriveEnv.
It would be hard to re-implement works based on Carla. Since works on carla use fixed maps with changing dynamic factors (ego car's spawn place / target place, other vehicle's spawn place, ...)
Also, I am training IL algorithm on 1-env setting and want to collect some expert data. I utilized pgdrive.examples.expert
but to find out that the collected trajectories were almost the same!
So, shall we provide an environment with decoupling map seed and traffic seed? Like:
env = PGDriveDecouplingEnv(dict=(environment_num=1, traffic_num=100))
A top-down view like highway-env to support more research topics. Besides, Carla and other simulators also provide a simple top down view render and multi-layer image observation.
I will add navigation line soon
We should:
self.pg_world.mode
and self.pg_world.pg_config["highway_render"]
.self.pg_world.pg_config["highway_render"]
in all places inside pg_world
.Therefore, we will have four strings to represent render mode in the internal PGWorld now:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.