bark-simulator / bark

Open-Source Framework for Development, Simulation and Benchmarking of Behavior Planning Algorithms for Autonomous Driving
https://bark-simulator.github.io/
MIT License
288 stars 69 forks source link

How to import the BehaviorRulesMcts model into the BARK workspace #578

Open mrzheng8 opened 2 years ago

mrzheng8 commented 2 years ago

I downloaded and ran the https://github.com/bark-simulator/planner-rules-mcts successfully. But it is a separate workspace. How can I use this BehaviorRulesMcts model in the BARK workspace.

mrzheng8 commented 2 years ago

I set it to bark.core.models.mcts The following is the error message:

WARNING: Logging before InitGoogleLogging() is written to STDERR F20220421 16:37:45.503643 1572 polymorphic_conversion.cpp:208] Unknown BehaviorType for polymorphic conversion to python: N4bark6models8behavior17BehaviorRulesMctsIN6mvmcts17ThresUCTStatisticEEE Check failure stack trace:

I think it may be related to the documents //bark/python_wrapper/models/plan/plan.hpp But I really can't understand how you connect the BehaviorRulesMcts model with this plan.hpp file in another space. I really can't understand how you merged it into bark.core.models.behavior

mrzheng8 commented 2 years ago

The following error occurred when I replaced the model name. I took a part of it. Why did this mistake happen? Is there an error in the header file mvmcts.h:79

WARNING: Logging before InitGoogleLogging() is written to STDERR I20220425 21:56:11.574766 1561 mvmcts.h:79] Max search samples: 2000 I20220425 21:56:11.574784 1561 mvmcts.h:85] starting state: 0# bark::commons::SegfaultHandler(int) in /home/su/.cache/bazel/_bazel_su/61c2ccfa09a92e90cc5125978445bf56/execroot/planner_rules_mcts/bazel-out/k8-fastbuild/bin/python/mctsceshi.runfiles/bark_project/bark/core.so 1# 0x00007FD1F2829F10 in /lib/x86_64-linux-gnu/libc.so.6 2# bark::models::behavior::MvmctsState::GetNumActions(unsigned char) const in /home/su/.cache/bazel/_bazel_su/61c2ccfa09a92e90cc5125978445bf56/execroot/planner_rules_mcts/bazel-out/k8-fastbuild/bin/python/mctsceshi.runfiles/bark_project/ba ... ... 37# __libc_start_main in /lib/x86_64-linux-gnu/libc.so.6 38# 0x00005587605C7773 in /home/su/planner-rules-mcts-master/python/venv/bin/python3

terminate called without an active exception 已放弃 (核心已转储)

CesarLiu commented 2 years ago

Hi, I think it' not necessary to put mcts in bark, and you can load it by configuration in bazel dependencies, like what has been done in here: https://github.com/bark-simulator/example_benchmark#behavior-models

best,