Skip to content
Merged
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
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,12 @@
'win-amd64' if os.name == 'nt' else 'linux-x86_64'))[0])
except IndexError:
pass

# 获取当前文件的目录
current_dir = os.path.dirname(os.path.abspath(__file__))
# 获取父目录
parent_dir = os.path.dirname(current_dir)
# 将父目录添加到系统路径
sys.path.append(parent_dir)
from agents.navigation.global_route_planner import GlobalRoutePlanner

import carla
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@
except IndexError:
pass

current_dir = os.path.dirname(os.path.abspath(__file__))
# 获取父目录
parent_dir = os.path.dirname(current_dir)
# 将父目录添加到系统路径
sys.path.append(parent_dir)
from agents.navigation.global_route_planner import GlobalRoutePlanner

import carla
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import os
import sys
os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2' # 只显示错误信息
import random
from collections import deque
Expand All @@ -13,11 +14,15 @@
from carla import Location
from carla import Rotation

current_dir = os.path.dirname(os.path.abspath(__file__))
base_dir = os.path.dirname(current_dir)
MODELS_DIR = os.path.join(base_dir, 'models')

town2 = {1: [53.12553405761719,137.06280517578125,1.3652913570404053, 0], 2:[105.81783294677734,97.80741882324219]}
curves = [0, town2]

epsilon = 0
MODEL_PATH = "models/Braking___282.model"
MODEL_PATH = os.path.join(MODELS_DIR, 'Braking___282.model')

def setup_tensorflow():
"""设置 TensorFlow 2.x 配置"""
Expand Down
Loading