Skip to content

Commit

Permalink
experimental_model typo
Browse files Browse the repository at this point in the history
  • Loading branch information
sshane committed Oct 11, 2024
1 parent f11e549 commit 21a8f9e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions selfdrive/ui/qt/onroad/model.cc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void ModelRenderer::draw(QPainter &painter, const QRect &surface_rect) {
}

clip_region = surface_rect.adjusted(-CLIP_MARGIN, -CLIP_MARGIN, CLIP_MARGIN, CLIP_MARGIN);
experimental_model = sm["selfdriveState"].getSelfdriveState().getExperimentalMode();
experimental_mode = sm["selfdriveState"].getSelfdriveState().getExperimentalMode();

painter.save();

Expand Down Expand Up @@ -107,7 +107,7 @@ void ModelRenderer::drawLaneLines(QPainter &painter) {

void ModelRenderer::drawPath(QPainter &painter, const cereal::ModelDataV2::Reader &model, int height) {
QLinearGradient bg(0, height, 0, 0);
if (experimental_model) {
if (experimental_mode) {
// The first half of track_vertices are the points for the right side of the path
const auto &acceleration = model.getAcceleration().getX();
const int max_len = std::min<int>(track_vertices.length() / 2, acceleration.size());
Expand Down
2 changes: 1 addition & 1 deletion selfdrive/ui/qt/onroad/model.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class ModelRenderer {
void drawPath(QPainter &painter, const cereal::ModelDataV2::Reader &model, int height);

bool longitudinal_control = false;
bool experimental_model = false;
bool experimental_mode = false;
float lane_line_probs[4] = {};
float road_edge_stds[2] = {};
QPolygonF track_vertices;
Expand Down

0 comments on commit 21a8f9e

Please sign in to comment.