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

Refactoring Plan #467

Open
2 of 9 tasks
pengzhenghao opened this issue Jul 9, 2021 · 2 comments
Open
2 of 9 tasks

Refactoring Plan #467

pengzhenghao opened this issue Jul 9, 2021 · 2 comments

Comments

@pengzhenghao
Copy link
Member

pengzhenghao commented Jul 9, 2021

To support future development, here is a refactoring plan. The major challenge is to decouple Pandas from PGDrive, in aspect such as rendering pipeline, vehicle initialization, and so on. Please feel free to change anything here and discuss with me @lqy0057 !


  • pgdrive
    • component: The elements that should be initialized at the very beginning and combined by managers.
      • vehicle
        • vehicle
        • phyics_vehicle
        • render_vehicle
      • object
        • obstacle
      • road
        • lane.py
        • road.py
        • ...
        • osm_parser
      • block
        • base_block.py
        • intersection.py
        • ...
      • policy
        • base_rule_based_policy.py
        • lane_following.py
      • obs
        • top_down_obs
        • lidar_state_obs.py
    • engine: The class that maintain the runtime workflow and pipeline.
      • engine.py
      • vehicle_manager
      • agent_manager
      • object_manager
      • scene_manager
        • algorithm
          • BIG.py
          • Future road network aggregation methods.
      • renderer
        • panda3d_renderer
    • env: The outer interfaces to users
      • general_interface
      • base_env
      • marl_env
        • base_marl_env.py
        • tollgate.py
        • ...
    • utils
      • config
        • pg_config
        • config_parser
      • visualization
        • top_down_drawing.py
        • ...
      • ...

Functions need to be re-implemented

  • replay and record system
  • step function of Light, Skybox, and Traffic Vehicle
  • random function check !
  • do NOT distinguish the configs in Object class and subclasses specific config, like config and vehicle config
  • assign class NAME for each object for a quick generation
  • heading theta for object
  • map needs to be re-generated due to the update of random engine
  • reorganize the code by using manager.before_step()/after_step()
  • clean np code in traffic manager
@pengzhenghao
Copy link
Member Author

@lqy0057 I have updated the plan according to our discussion (0712), please check.
This is simply the code structure, but the conceptual figure is not written here.

@QuanyiLi
Copy link
Collaborator

I have prepared a complete refactor plan, I will share it with you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants