-
Notifications
You must be signed in to change notification settings - Fork 1.2k
TOYOTA_RAV4_PRIME NNLC tuning gen 1 #850
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
TOYOTA_RAV4_PRIME NNLC tuning gen 1 #850
Conversation
Reviewer's Guide by SourceryThe pull request updates the neural network model for the TOYOTA_RAV4_PRIME, resulting in a more refined tuning. The new model was trained on a 2023 RAV4 Prime XSE and demonstrates improved handling of high torque curves and a smoother instantaneous lateral jerk response. No diagrams generated as the changes look simple and do not need a visual representation. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
b6d9439 to
af7898a
Compare
|
The |
|
By kumar's request pushed again. No change except |
* Bump tinygrad to upstream master (#34973) bump tg * test_onroad: test liveParameters service timing (#34977) Add live params to test onroad * selfdrived: remove ignored processes list (#34978) * selfdrived: remove ignored processes list * it's a set * calibrationd: read carParams from Params (#34981) * Read CarParams once from Params * Remove it from process replay * locationd: make pose_kf inherit from KalmanFilter (#34982) * Read message not json for initial state * Delete lines * Fix param * MADS: prevent `wrongCarMode` from disabling MADS enabled state (sunnypilot#792) * MADS: prevent `wrongCarMode` from disabling MADS enabled state Add wrongCarModeNoEntry as a NO_ENTRY event to replace wrongCarMode (USER_DISABLE) that would incorrectly disable MADS when in the wrong car mode. Provides contextual guidance to users based on car brand, showing appropriate instructions for re-engagement without requiring MADS to be re-enabled. * move down * warning only? * cereal SIKE * remove duplicate * try this out * final * Readme: update with links to new branches and info about rewrite and reflash agnos (sunnypilot#795) * Adding the new branches info and adding a warning to reflash agnos * Using more blockquote * it --------- Co-authored-by: Stupefacient <[email protected]> * agnos 11.13 (#34980) * agnos 11.12 * new build * Multilang: Update pt-BR translation (#34983) * [bot] Update Python packages (#34987) Update Python packages Co-authored-by: Vehicle Researcher <[email protected]> * Multilang: Update ja translation (#34986) * 日本語訳2025/3/19 * numerusform追加。 * connect to an unmetered networkに対応 * panda是正 * opendbc_repo是正 * Multilang: Update zh translation (#34985) * update to latest userdata partition (#34990) update * paramsd: cache backwards compatibility (#34991) * LiveParametersV2 key * Param key * Fix tests * Remove old params if error * Update exception message * Update the test * Add test for corrupted byte format in v1 * Rename params_reader => params * hardwared: give stuck LTE connections a kick This reverts commit e3e6940. * Revert "hardwared: give stuck LTE connections a kick" This reverts commit e4aa346. * process_replay: fix GM and replace TOYOTA3 (#34996) * Add volt and bolt param migration * Remove mazda due to invalid sensor timings * Fix the import * Add mazda to excluded * Bring back mazda, but add todo * New segment for TOYOTA3 * Fix * Update ref commit * bump opendbc * test_models: update relay malfunction check (#34999) relay is checked in fwd hook * process_replay: remove GM (volt) (#35000) Remove volt segment * Revert "test_models: update relay malfunction check" (#35002) Revert "test_models: update relay malfunction check (#34999)" This reverts commit 2cd0079. * Reapply "Online lateral lag learning" (#34975) * Online lateral lag learning (#34974) This reverts commit b4cc9e6. * pad to the best size for fft * Fix static analysis * Add typing * Fix typing * MAX_LAG * Calculate cross correlation regardless if the points are valid * Back to lagd * Add lagd to process_config * Lagd in test onroad * Move lag estimator for lagd * Remove duplicate entry from test_onroad * Update process replay * pre-fill the data * Update cpu usage * 25sec window * Change the meaning of lateralDelayEstimate * No newline * Fix typing * Prefill * Update ref commit * Add a unit test * Fix static issues * Time limit * Or timeout * Use mocker * Update estimate every time * empty test * DT const * enable RIVIAN again * Update ref commit * Update that again * Improve the tests * Fix static * Add masking test * Increase timeout * Add liveDelay to selfdrived * Add liveDelay to selfdrived in process_replay * Fix block_avg restore after num_blocks * regen most * Update bolt * Update ref commit * Change the key name * Add assert * True weighted average * Raise thermal setpoint (#35008) We don't need to control all the way down to 70C * UI: Update `AbstractControlSP_SELECTOR` and `OptionControlSP` (sunnypilot#800) * controls * Adjust label width dynamically based on layout type. Updated the label's fixed width to be conditional on the layout type, improving adaptability for different inline layouts. Additionally, corrected indentation in the width calculation loop for consistency. * Refactor OptionControlSP to improve parameter value handling and encapsulate logic in dedicated methods * Refactor getParamValue to return an integer and ensure value is updated correctly in button click handler * Trying to unify a bit the logic. still WIP * Reducing a bit the change footprint * Refactor spacing item handling to prevent duplicate insertion and improve layout management --------- Co-authored-by: DevTekVE <[email protected]> * bump panda * Radard: vision-based yRel for Hyundai single-lead systems (sunnypilot#805) Introduced processing for custom yRel values using HyundaiFlagsSP when the enhanced SCC flag is enabled. Updated `radard` to handle `CarParamsSP` and make necessary adjustments for Hyundai vehicles with specific SCC configurations. * MADS: transition to soft-disable for specific gear states (sunnypilot#791) * MADS: transition to soft-disable for specific gear states This commit enhances the condition checking functionality of the Modular Assistive Driving System (MADS) to implement a 'soft-disable' feature during the vehicle's active motion when a non-forward drive gear is engaged. It includes utilizing structs to reference various car state attributes and modifying a function definition to improve clarity. This adjustment boosts the system's reaction to gear shifts, increasing the safety and efficiency of the driving assist system. * structs * UI: Device & Sunnylink Panels - Standardize push button size & alignment (sunnypilot#806) * layout adjustments * sunnylink_panel --------- Co-authored-by: Jason Wen <[email protected]> * [bot] Update Python packages (#35012) * Update Python packages * update refs --------- Co-authored-by: Vehicle Researcher <[email protected]> Co-authored-by: Shane Smiskol <[email protected]> * ci: Remove redundant Panda build step from prebuilt workflow (sunnypilot#810) The Panda build step was unnecessary as it is not utilized in this workflow. This change simplifies the workflow and reduces redundant actions, improving efficiency. * Device: Customizable Max Time Offroad (sunnypilot#796) * Max Time Offroad * Refactor & Fix param * Error Handling * rename SP variable * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.cc Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/offroad/settings/lateral/max_time_offroad.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/offroad/settings/lateral/max_time_offroad.cc Co-authored-by: DevTekVE <[email protected]> * UI layout changes for better alignment selector is not big enough -> make it bigger ;) OptionControlSP now includes a QMap argument to allow actual values to be set in param directly * Rebase & resolve reviews * change default to be closer to OP default * me dumb * MaxTimeOffroad: Add support for 30h limit and improve label formatting * power_monitoring: Refactor MaxTimeOffroad parameter handling for clarity * test: Add unit tests for MaxTimeOffroad parameter handling * power_monitoring: Update MaxTimeOffroad handling to use seconds and improve shutdown logic * power_monitoring: Improve exception handling and remove redundant shutdown check for MaxTimeOffroad --------- Co-authored-by: DevTekVE <[email protected]> Co-authored-by: Jason Wen <[email protected]> * Hyundai longitudinal: Parse lead info for camera-based SCC platforms (sunnypilot#809) * Hyundai longitudinal: Parse lead info for camera-based SCC platforms * fix * update * bump * update tests * lol why is this here * bump --------- Co-authored-by: DevTekVE <[email protected]> Co-authored-by: Discountchubbs <[email protected]> * Models: point to v2 of driving models json for recompiled models (sunnypilot#817) Use newer model version json since they have been recompiled * ci: update squash script for external contributors (sunnypilot#811) * Get head ref info * Simpify adding the comment with the newest flagg by gh cli * Dynamic origin * Enhance PR processing: add label handling for forked PRs and improve variable naming * Refactor PR label handling: use constant for trust-fork label and improve comments * Fix remote addition in PR processing: change subprocess call to not check for errors * Refactor PR comment handling: support multiple comments and improve clarity * Refactor PR processing: streamline comment handling and improve error management * Refactor add_pr_comments function: specify comments type as list of strings * Maybe we don't prevent "behind" branches to be merged as lon as the PR itself is mergeable * lint, leave me alone --------- Co-authored-by: Discountchubbs <[email protected]> * sunnylink: fix sunnylink backup restore version parsing (sunnypilot#816) * improvement * fix: Improve version parsing logic for sunnypilot --------- Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Jason Wen <[email protected]> * DM: Enforce monitoring of MADS state in driver monitoring (sunnypilot#818) * DM: Enforce monitoring of MADS state in driver monitoring Added `selfdriveStateSP.mads.enabled` to track MADS engagement. This ensures monitoring logic accounts for MADS alongside the existing selfdrive state checks, improving feature integration and event handling. * how * [bot] Update Python packages (#35017) Update Python packages Co-authored-by: Vehicle Researcher <[email protected]> * Rename experimental long (#35011) * now alpha long * fix * rename param * thought i did this * debug * debug * more * more * moar * Revert "moar" This reverts commit e347106246583982e1be206485ad4d8eb944f817. * Revert "more" This reverts commit 0746e6d2e400ce1715614c62af84a9680c4d65c1. * Revert "more" This reverts commit 0db5a8792c01bb2d687f9152e6ba37fb76d4a453. * Revert "debug" This reverts commit 72f235b13727980e4331ff487998ddc7c7f7fb63. * Revert "debug" This reverts commit 7871b69f8c1bdffed386c2baac99542fcc50f7eb. * Temporary disable UI preview from CI (#35018) disable * Update Python packages (sunnypilot#819) * Fix possible CAN ignition overlap due to incorrect counter tracking (#35019) * fix-rivian-ign * bump * UI: Bugfix Max Time Offroad (sunnypilot#820) bugfixes Co-authored-by: Discountchubbs <[email protected]> * CI: Improve `dev-c3-new` auto build (sunnypilot#825) * force commit to force PR * ci: add job to manage PR labels and remove trust label on new commits * Add pull request trigger * empty commit to test * ci: update pull request label management logic and remove FORCE_RUN flag * ci: update trust label management to use TRUST_FORK_PR_LABEL * ci: update workflow to manage PR labels and adjust trigger conditions * ci: rename jobs in workflow for consistency and clarity * ci: add unleash-nightly-squash branch to workflow * ci: add checkout step with GITHUB_TOKEN to workflow * force wait * what happens if negated the wait * ci: add 'Wait for Tests' action to monitor workflow execution * ci: update wait-for-tests action conditions and cleanup * ci: refine conditions for managing PR labels and waiting for tests * ci: enhance PR label conditions for workflow execution * Cant use env on if * maybe * ci: update pull request workflow conditions and cleanup * Missing end of line * ci: rename workflow and update job name for clarity * Cleaning * ci: refine conditions for pull request handling in workflow * ci: update handling of TRUST_FORK_LABEL in PR processing * ci: remove fork trust warning from PR processing --------- Co-authored-by: Jason Wen <[email protected]> * CI: Update PR list query to exclude draft pull requests (sunnypilot#829) * lagd: check sensors valid (#35027) * Check if sensors valid * Fix test * Fix static * Constants * time buffer for pose valid * Fix static * Revert "DM: Enforce monitoring of MADS state in driver monitoring" (sunnypilot#830) Revert "DM: Enforce monitoring of MADS state in driver monitoring (sunnypilot#818)" This reverts commit 3615b1a. * DM: Enforce monitoring of MADS state in driver monitoring (sunnypilot#831) * DM: Enforce monitoring of MADS state in driver monitoring Added `selfdriveStateSP.mads.enabled` to track MADS engagement. This ensures monitoring logic accounts for MADS alongside the existing selfdrive state checks, improving feature integration and event handling. * how * okay, only when active * ui(raylib): update spinner progress bar to match Qt (#35028) * lagd: estimate std (#35009) * Std * Fix static * Refactor * Assert std zero * update * ui(raylib): fix typos (#35030) * Update modeld action logic (#35032) * add action logic * magic numbers * unused * plot accel * more changes * lagd: check for validity of the estimate when restoring state (#35034) Do not restore if invalid * Multilang: Update de translation (#35025) added missing German translations * Tomb raider 2 (#35029) * db56b8fb-9135-4ab6-af18-99b7df7b2245/400 * fixes * linter unhappy * 6dbe0991-baa1-49ad-836a-ab370d1f0d92/400 * This one is good: 19387087-1005-475e-9015-9458dd8e7c5f/400 * Better every day: 39ed911c-0937-417f-97d2-58a8bb3caa53/400 * Actually end-to-end * typo * smooooooth: 94e23541-eb84-4fef-9f51-6a2d82aff314/360 * Revert "smooooooth: 94e23541-eb84-4fef-9f51-6a2d82aff314/360" This reverts commit edd4f02386d83d82dd8a188985cde80ed1646b7f. * 11632ef7-f555-489c-8480-e3bf97d9285e/400 * 08712d27-f6bd-4536-a30e-c729e5f62356/400 * 0a92a35e-1f72-476a-8cb6-c9f103f36822/400 * ee6d2394-2072-420c-a664-b4c0d4ed0b61/400 * no prev curv * No double work * fix bug * smooth * update prev action * whitespace * add little accel * new ref * Update plant.py * DEC: adjust dynamic speed adaptation parameters (sunnypilot#813) * early and better * Update sunnypilot/selfdrive/controls/lib/dec/constants.py --------- Co-authored-by: Jason Wen <[email protected]> Co-authored-by: Discountchubbs <[email protected]> * OS04C10: use IFE downscaler for road cameras (#35023) * squashh * wrong * clean up * rename * process replay migration: fix longitudinalPlan (#35035) * ci: ui preview add unicode characters and emojis (sunnypilot#835) Add unicode characters and emojis! * ui(raylib): update text window font, new lines and indentation (#35031) * NNLC: decreased low-speed factor (sunnypilot#822) * NNLC: decreased low-speed factor * np.float to float * format * add tests for sanity check --------- Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Jason Wen <[email protected]> * ui(raylib): calculate spinner progress in set_text (#35036) * bugfix: Auto lane change - Add mode to disable lane changes (sunnypilot#826) * off is off * sugg * line * Update sunnypilot/selfdrive/controls/lib/tests/test_auto_lane_change.py --------- Co-authored-by: Jason Wen <[email protected]> Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: DevTekVE <[email protected]> * NNLC: use `safe_exp` to prevent overflow in `sigmoid` (sunnypilot#836) * test * prevent overflowing * unused * NNLC: fix weak torque in high lat-accel turns (sunnypilot#823) * NNLC: fix weak torque in high lat-accel turns * np.float to float --------- Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Jason Wen <[email protected]> * ci: trigger prebuilt builds via label from PR * ci: enhance pull request handling for prebuilt workflows * ci: add wait-for-action step to monitor selfdrive_tests workflow * ci: add validation job to monitor selfdrive_tests for prebuilt workflows * test * force negative condition to validate flow * force negative condition to validate flow * ci: add wait_for_tests input to control selfdrive_tests workflow execution * ci: update description for wait_for_tests input in workflow * Cleaning * Remove PR label when triggered by the label * Rename * Changing to target and only caring about labeled for the time being * gh action needs cancelled not canceled * Line ending * ci: avoid deadlock on dev-c3 branch build when PR labeled dev-c3 (sunnypilot#839) * ci: enhance PR checks to validate individual check runs before merging and ignore reset-and-squash as candidate for fail * reset and squash script shouldn't will be cancelled only if a push to master has been made which always should take priority. The rest will be put on hold to avoid parallel squash scripts running * Set concurrencty at workflow level? * Set concurrencty at workflow level? * change trigger to pull_request to validate * Reducing the types of "pull request" events * Keep it as target * Playing eith run name a little * Change to pull request not target * simplifying * set to just pull request without target * maintain as pull request target * ci: update auto pr review config and split turst fork pr (sunnypilot#842) * Updating auto pr labeler * auto pr review revamp * Leaving event as pull request :) * Check permission * add chore * Bringing back as original * ci: bugfix flipped contains check for pull requests * ci: bugfix cancelling only when push to master or workflow dispatch. Otherwise don't let it cancel as it seems that when running with pull_request_target we are with ref pointing to target and thus the cancel condition was being met * ui(raylib): constant spinner rotation speed (#35037) * ci: improve conditions for publish and notify steps in workflow (sunnypilot#844) * [bot] Update translations (#35040) Update translations Co-authored-by: Vehicle Researcher <[email protected]> * Long planner: make work with training (#35043) * revert useless * update ref * Modeld: small refactor (#35044) refactor * update smooth * raylib: init updater (#35045) * raylib: init updater * cleanup * Revert "OS04C10: use IFE downscaler for road cameras" (#35046) Revert "OS04C10: use IFE downscaler for road cameras (#35023)" This reverts commit 3b60b22. * Tomb Raider 3 (#35042) * 92b64884-4506-4a03-87ad-33e1a177fe73/400 * faster lat * DM: Use `carControl.latActive` for MADS DM monitoring (sunnypilot#845) * ci: fixes for trigger conditions on sync (sunnypilot#847) pull_request_target is needed for security, but at the same time it makes life a little harder because the ref is different so we need to do some work to make sure we get what we are supposed to get * ui(raylib): reduce spinner rotation artifact (#35048) * ui(raylib): reduce spinner rotation artifact A visual artifact (white pixels) appeared on the edge of the rotating spinner track texture, likely due to RGB color bleed during bilinear filtering in Raylib. Pre-multiplying the alpha channel of the spinner track image using `rl.image_alpha_premultiply` significantly reduces the visibility of the artifact. * lint * ui(raylib): increase font size and wrap text in spinner (#35049) - Wrap text onto separate lines - Increase font size to be closer to Qt - Remove extra letter spacing - 0.0 should use font default spacing, and this is used in `wrap_text` Will fix vertical alignment separately, as both the text and progress bar layouts need to be considered * ui(raylib): update spinner vertical pos (#35051) Adjust the spinner vertical position when displaying text or a progress bar - When displaying the progress bar, center the comma logo and spinner in the middle of the screen - When displaying text, center the entire content vertically Also updated `wrap_text` to not include an empty line in the array if it's the first line, so that `wrap_text("")` always returns `[]` * ui(raylib): "exit" btn in text window on PC (#35052) * ui(raylib): "exit" btn in text window on PC * unused import * Revert "ui(raylib): "exit" btn in text window on PC (#35052)" This reverts commit f9767d2. * plotjuggler: support relative paths (#35054) * Support relative paths * Abspath for rlog too * Reapply "ui(raylib): "exit" btn in text window on PC" (#35053) * ui(raylib): "exit" btn in text window on PC * unused import * request close * this was missing * Disable low speed steer in modeld (#35056) * disable low speed steer * No steer under * TOYOTA_RAV4_PRIME NNLC tuning gen 1 (sunnypilot#850) neural_network_data: TOYOTA_RAV4_PRIME NNLC tuning gen 1 * SL: updating localproxy implementation (sunnypilot#841) * Adding capabilities to route localProxy via sunnylink * Undo * Thx lint * get api token * cert is not valid when it's an IP. Still use cert, but don't validate * move to car_specific_sp * bump --------- Co-authored-by: Harald Schäfer <[email protected]> Co-authored-by: Kacper Rączy <[email protected]> Co-authored-by: Adeeb Shihadeh <[email protected]> Co-authored-by: Jason Wen <[email protected]> Co-authored-by: DevTekVE <[email protected]> Co-authored-by: Stupefacient <[email protected]> Co-authored-by: Alexandre Nobuharu Sato <[email protected]> Co-authored-by: commaci-public <[email protected]> Co-authored-by: Vehicle Researcher <[email protected]> Co-authored-by: programanichiro <[email protected]> Co-authored-by: eFini <[email protected]> Co-authored-by: Maxime Desroches <[email protected]> Co-authored-by: Shane Smiskol <[email protected]> Co-authored-by: Robbe Derks <[email protected]> Co-authored-by: Nayan <[email protected]> Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Cameron Clough <[email protected]> Co-authored-by: niko001 <[email protected]> Co-authored-by: Kumar <[email protected]> Co-authored-by: ZwX1616 <[email protected]> Co-authored-by: YassineYousfi <[email protected]> Co-authored-by: Tim Wilson <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Warren Togami <[email protected]>
* FCA: Ram 1500 improvements * updating reference to my opendbc * syncing latest opendbc * move to car_specific_sp * bump * Realfast ram1500 (#1) * Bump tinygrad to upstream master (#34973) bump tg * test_onroad: test liveParameters service timing (#34977) Add live params to test onroad * selfdrived: remove ignored processes list (#34978) * selfdrived: remove ignored processes list * it's a set * calibrationd: read carParams from Params (#34981) * Read CarParams once from Params * Remove it from process replay * locationd: make pose_kf inherit from KalmanFilter (#34982) * Read message not json for initial state * Delete lines * Fix param * MADS: prevent `wrongCarMode` from disabling MADS enabled state (#792) * MADS: prevent `wrongCarMode` from disabling MADS enabled state Add wrongCarModeNoEntry as a NO_ENTRY event to replace wrongCarMode (USER_DISABLE) that would incorrectly disable MADS when in the wrong car mode. Provides contextual guidance to users based on car brand, showing appropriate instructions for re-engagement without requiring MADS to be re-enabled. * move down * warning only? * cereal SIKE * remove duplicate * try this out * final * Readme: update with links to new branches and info about rewrite and reflash agnos (#795) * Adding the new branches info and adding a warning to reflash agnos * Using more blockquote * it --------- Co-authored-by: Stupefacient <[email protected]> * agnos 11.13 (#34980) * agnos 11.12 * new build * Multilang: Update pt-BR translation (#34983) * [bot] Update Python packages (#34987) Update Python packages Co-authored-by: Vehicle Researcher <[email protected]> * Multilang: Update ja translation (#34986) * 日本語訳2025/3/19 * numerusform追加。 * connect to an unmetered networkに対応 * panda是正 * opendbc_repo是正 * Multilang: Update zh translation (#34985) * update to latest userdata partition (#34990) update * paramsd: cache backwards compatibility (#34991) * LiveParametersV2 key * Param key * Fix tests * Remove old params if error * Update exception message * Update the test * Add test for corrupted byte format in v1 * Rename params_reader => params * hardwared: give stuck LTE connections a kick This reverts commit e3e6940. * Revert "hardwared: give stuck LTE connections a kick" This reverts commit e4aa346. * process_replay: fix GM and replace TOYOTA3 (#34996) * Add volt and bolt param migration * Remove mazda due to invalid sensor timings * Fix the import * Add mazda to excluded * Bring back mazda, but add todo * New segment for TOYOTA3 * Fix * Update ref commit * bump opendbc * test_models: update relay malfunction check (#34999) relay is checked in fwd hook * process_replay: remove GM (volt) (#35000) Remove volt segment * Revert "test_models: update relay malfunction check" (#35002) Revert "test_models: update relay malfunction check (#34999)" This reverts commit 2cd0079. * Reapply "Online lateral lag learning" (#34975) * Online lateral lag learning (#34974) This reverts commit b4cc9e6. * pad to the best size for fft * Fix static analysis * Add typing * Fix typing * MAX_LAG * Calculate cross correlation regardless if the points are valid * Back to lagd * Add lagd to process_config * Lagd in test onroad * Move lag estimator for lagd * Remove duplicate entry from test_onroad * Update process replay * pre-fill the data * Update cpu usage * 25sec window * Change the meaning of lateralDelayEstimate * No newline * Fix typing * Prefill * Update ref commit * Add a unit test * Fix static issues * Time limit * Or timeout * Use mocker * Update estimate every time * empty test * DT const * enable RIVIAN again * Update ref commit * Update that again * Improve the tests * Fix static * Add masking test * Increase timeout * Add liveDelay to selfdrived * Add liveDelay to selfdrived in process_replay * Fix block_avg restore after num_blocks * regen most * Update bolt * Update ref commit * Change the key name * Add assert * True weighted average * Raise thermal setpoint (#35008) We don't need to control all the way down to 70C * UI: Update `AbstractControlSP_SELECTOR` and `OptionControlSP` (#800) * controls * Adjust label width dynamically based on layout type. Updated the label's fixed width to be conditional on the layout type, improving adaptability for different inline layouts. Additionally, corrected indentation in the width calculation loop for consistency. * Refactor OptionControlSP to improve parameter value handling and encapsulate logic in dedicated methods * Refactor getParamValue to return an integer and ensure value is updated correctly in button click handler * Trying to unify a bit the logic. still WIP * Reducing a bit the change footprint * Refactor spacing item handling to prevent duplicate insertion and improve layout management --------- Co-authored-by: DevTekVE <[email protected]> * bump panda * Radard: vision-based yRel for Hyundai single-lead systems (#805) Introduced processing for custom yRel values using HyundaiFlagsSP when the enhanced SCC flag is enabled. Updated `radard` to handle `CarParamsSP` and make necessary adjustments for Hyundai vehicles with specific SCC configurations. * MADS: transition to soft-disable for specific gear states (#791) * MADS: transition to soft-disable for specific gear states This commit enhances the condition checking functionality of the Modular Assistive Driving System (MADS) to implement a 'soft-disable' feature during the vehicle's active motion when a non-forward drive gear is engaged. It includes utilizing structs to reference various car state attributes and modifying a function definition to improve clarity. This adjustment boosts the system's reaction to gear shifts, increasing the safety and efficiency of the driving assist system. * structs * UI: Device & Sunnylink Panels - Standardize push button size & alignment (#806) * layout adjustments * sunnylink_panel --------- Co-authored-by: Jason Wen <[email protected]> * [bot] Update Python packages (#35012) * Update Python packages * update refs --------- Co-authored-by: Vehicle Researcher <[email protected]> Co-authored-by: Shane Smiskol <[email protected]> * ci: Remove redundant Panda build step from prebuilt workflow (#810) The Panda build step was unnecessary as it is not utilized in this workflow. This change simplifies the workflow and reduces redundant actions, improving efficiency. * Device: Customizable Max Time Offroad (#796) * Max Time Offroad * Refactor & Fix param * Error Handling * rename SP variable * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/widgets/controls.cc Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/offroad/settings/lateral/max_time_offroad.h Co-authored-by: DevTekVE <[email protected]> * Update selfdrive/ui/sunnypilot/qt/offroad/settings/lateral/max_time_offroad.cc Co-authored-by: DevTekVE <[email protected]> * UI layout changes for better alignment selector is not big enough -> make it bigger ;) OptionControlSP now includes a QMap argument to allow actual values to be set in param directly * Rebase & resolve reviews * change default to be closer to OP default * me dumb * MaxTimeOffroad: Add support for 30h limit and improve label formatting * power_monitoring: Refactor MaxTimeOffroad parameter handling for clarity * test: Add unit tests for MaxTimeOffroad parameter handling * power_monitoring: Update MaxTimeOffroad handling to use seconds and improve shutdown logic * power_monitoring: Improve exception handling and remove redundant shutdown check for MaxTimeOffroad --------- Co-authored-by: DevTekVE <[email protected]> Co-authored-by: Jason Wen <[email protected]> * Hyundai longitudinal: Parse lead info for camera-based SCC platforms (#809) * Hyundai longitudinal: Parse lead info for camera-based SCC platforms * fix * update * bump * update tests * lol why is this here * bump --------- Co-authored-by: DevTekVE <[email protected]> Co-authored-by: Discountchubbs <[email protected]> * Models: point to v2 of driving models json for recompiled models (#817) Use newer model version json since they have been recompiled * ci: update squash script for external contributors (#811) * Get head ref info * Simpify adding the comment with the newest flagg by gh cli * Dynamic origin * Enhance PR processing: add label handling for forked PRs and improve variable naming * Refactor PR label handling: use constant for trust-fork label and improve comments * Fix remote addition in PR processing: change subprocess call to not check for errors * Refactor PR comment handling: support multiple comments and improve clarity * Refactor PR processing: streamline comment handling and improve error management * Refactor add_pr_comments function: specify comments type as list of strings * Maybe we don't prevent "behind" branches to be merged as lon as the PR itself is mergeable * lint, leave me alone --------- Co-authored-by: Discountchubbs <[email protected]> * sunnylink: fix sunnylink backup restore version parsing (#816) * improvement * fix: Improve version parsing logic for sunnypilot --------- Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Jason Wen <[email protected]> * DM: Enforce monitoring of MADS state in driver monitoring (#818) * DM: Enforce monitoring of MADS state in driver monitoring Added `selfdriveStateSP.mads.enabled` to track MADS engagement. This ensures monitoring logic accounts for MADS alongside the existing selfdrive state checks, improving feature integration and event handling. * how * [bot] Update Python packages (#35017) Update Python packages Co-authored-by: Vehicle Researcher <[email protected]> * Rename experimental long (#35011) * now alpha long * fix * rename param * thought i did this * debug * debug * more * more * moar * Revert "moar" This reverts commit e347106246583982e1be206485ad4d8eb944f817. * Revert "more" This reverts commit 0746e6d2e400ce1715614c62af84a9680c4d65c1. * Revert "more" This reverts commit 0db5a8792c01bb2d687f9152e6ba37fb76d4a453. * Revert "debug" This reverts commit 72f235b13727980e4331ff487998ddc7c7f7fb63. * Revert "debug" This reverts commit 7871b69f8c1bdffed386c2baac99542fcc50f7eb. * Temporary disable UI preview from CI (#35018) disable * Update Python packages (#819) * Fix possible CAN ignition overlap due to incorrect counter tracking (#35019) * fix-rivian-ign * bump * UI: Bugfix Max Time Offroad (#820) bugfixes Co-authored-by: Discountchubbs <[email protected]> * CI: Improve `dev-c3-new` auto build (#825) * force commit to force PR * ci: add job to manage PR labels and remove trust label on new commits * Add pull request trigger * empty commit to test * ci: update pull request label management logic and remove FORCE_RUN flag * ci: update trust label management to use TRUST_FORK_PR_LABEL * ci: update workflow to manage PR labels and adjust trigger conditions * ci: rename jobs in workflow for consistency and clarity * ci: add unleash-nightly-squash branch to workflow * ci: add checkout step with GITHUB_TOKEN to workflow * force wait * what happens if negated the wait * ci: add 'Wait for Tests' action to monitor workflow execution * ci: update wait-for-tests action conditions and cleanup * ci: refine conditions for managing PR labels and waiting for tests * ci: enhance PR label conditions for workflow execution * Cant use env on if * maybe * ci: update pull request workflow conditions and cleanup * Missing end of line * ci: rename workflow and update job name for clarity * Cleaning * ci: refine conditions for pull request handling in workflow * ci: update handling of TRUST_FORK_LABEL in PR processing * ci: remove fork trust warning from PR processing --------- Co-authored-by: Jason Wen <[email protected]> * CI: Update PR list query to exclude draft pull requests (#829) * lagd: check sensors valid (#35027) * Check if sensors valid * Fix test * Fix static * Constants * time buffer for pose valid * Fix static * Revert "DM: Enforce monitoring of MADS state in driver monitoring" (#830) Revert "DM: Enforce monitoring of MADS state in driver monitoring (#818)" This reverts commit 3615b1a. * DM: Enforce monitoring of MADS state in driver monitoring (#831) * DM: Enforce monitoring of MADS state in driver monitoring Added `selfdriveStateSP.mads.enabled` to track MADS engagement. This ensures monitoring logic accounts for MADS alongside the existing selfdrive state checks, improving feature integration and event handling. * how * okay, only when active * ui(raylib): update spinner progress bar to match Qt (#35028) * lagd: estimate std (#35009) * Std * Fix static * Refactor * Assert std zero * update * ui(raylib): fix typos (#35030) * Update modeld action logic (#35032) * add action logic * magic numbers * unused * plot accel * more changes * lagd: check for validity of the estimate when restoring state (#35034) Do not restore if invalid * Multilang: Update de translation (#35025) added missing German translations * Tomb raider 2 (#35029) * db56b8fb-9135-4ab6-af18-99b7df7b2245/400 * fixes * linter unhappy * 6dbe0991-baa1-49ad-836a-ab370d1f0d92/400 * This one is good: 19387087-1005-475e-9015-9458dd8e7c5f/400 * Better every day: 39ed911c-0937-417f-97d2-58a8bb3caa53/400 * Actually end-to-end * typo * smooooooth: 94e23541-eb84-4fef-9f51-6a2d82aff314/360 * Revert "smooooooth: 94e23541-eb84-4fef-9f51-6a2d82aff314/360" This reverts commit edd4f02386d83d82dd8a188985cde80ed1646b7f. * 11632ef7-f555-489c-8480-e3bf97d9285e/400 * 08712d27-f6bd-4536-a30e-c729e5f62356/400 * 0a92a35e-1f72-476a-8cb6-c9f103f36822/400 * ee6d2394-2072-420c-a664-b4c0d4ed0b61/400 * no prev curv * No double work * fix bug * smooth * update prev action * whitespace * add little accel * new ref * Update plant.py * DEC: adjust dynamic speed adaptation parameters (#813) * early and better * Update sunnypilot/selfdrive/controls/lib/dec/constants.py --------- Co-authored-by: Jason Wen <[email protected]> Co-authored-by: Discountchubbs <[email protected]> * OS04C10: use IFE downscaler for road cameras (#35023) * squashh * wrong * clean up * rename * process replay migration: fix longitudinalPlan (#35035) * ci: ui preview add unicode characters and emojis (#835) Add unicode characters and emojis! * ui(raylib): update text window font, new lines and indentation (#35031) * NNLC: decreased low-speed factor (#822) * NNLC: decreased low-speed factor * np.float to float * format * add tests for sanity check --------- Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Jason Wen <[email protected]> * ui(raylib): calculate spinner progress in set_text (#35036) * bugfix: Auto lane change - Add mode to disable lane changes (#826) * off is off * sugg * line * Update sunnypilot/selfdrive/controls/lib/tests/test_auto_lane_change.py --------- Co-authored-by: Jason Wen <[email protected]> Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: DevTekVE <[email protected]> * NNLC: use `safe_exp` to prevent overflow in `sigmoid` (#836) * test * prevent overflowing * unused * NNLC: fix weak torque in high lat-accel turns (#823) * NNLC: fix weak torque in high lat-accel turns * np.float to float --------- Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Jason Wen <[email protected]> * ci: trigger prebuilt builds via label from PR * ci: enhance pull request handling for prebuilt workflows * ci: add wait-for-action step to monitor selfdrive_tests workflow * ci: add validation job to monitor selfdrive_tests for prebuilt workflows * test * force negative condition to validate flow * force negative condition to validate flow * ci: add wait_for_tests input to control selfdrive_tests workflow execution * ci: update description for wait_for_tests input in workflow * Cleaning * Remove PR label when triggered by the label * Rename * Changing to target and only caring about labeled for the time being * gh action needs cancelled not canceled * Line ending * ci: avoid deadlock on dev-c3 branch build when PR labeled dev-c3 (#839) * ci: enhance PR checks to validate individual check runs before merging and ignore reset-and-squash as candidate for fail * reset and squash script shouldn't will be cancelled only if a push to master has been made which always should take priority. The rest will be put on hold to avoid parallel squash scripts running * Set concurrencty at workflow level? * Set concurrencty at workflow level? * change trigger to pull_request to validate * Reducing the types of "pull request" events * Keep it as target * Playing eith run name a little * Change to pull request not target * simplifying * set to just pull request without target * maintain as pull request target * ci: update auto pr review config and split turst fork pr (#842) * Updating auto pr labeler * auto pr review revamp * Leaving event as pull request :) * Check permission * add chore * Bringing back as original * ci: bugfix flipped contains check for pull requests * ci: bugfix cancelling only when push to master or workflow dispatch. Otherwise don't let it cancel as it seems that when running with pull_request_target we are with ref pointing to target and thus the cancel condition was being met * ui(raylib): constant spinner rotation speed (#35037) * ci: improve conditions for publish and notify steps in workflow (#844) * [bot] Update translations (#35040) Update translations Co-authored-by: Vehicle Researcher <[email protected]> * Long planner: make work with training (#35043) * revert useless * update ref * Modeld: small refactor (#35044) refactor * update smooth * raylib: init updater (#35045) * raylib: init updater * cleanup * Revert "OS04C10: use IFE downscaler for road cameras" (#35046) Revert "OS04C10: use IFE downscaler for road cameras (#35023)" This reverts commit 3b60b22. * Tomb Raider 3 (#35042) * 92b64884-4506-4a03-87ad-33e1a177fe73/400 * faster lat * DM: Use `carControl.latActive` for MADS DM monitoring (#845) * ci: fixes for trigger conditions on sync (#847) pull_request_target is needed for security, but at the same time it makes life a little harder because the ref is different so we need to do some work to make sure we get what we are supposed to get * ui(raylib): reduce spinner rotation artifact (#35048) * ui(raylib): reduce spinner rotation artifact A visual artifact (white pixels) appeared on the edge of the rotating spinner track texture, likely due to RGB color bleed during bilinear filtering in Raylib. Pre-multiplying the alpha channel of the spinner track image using `rl.image_alpha_premultiply` significantly reduces the visibility of the artifact. * lint * ui(raylib): increase font size and wrap text in spinner (#35049) - Wrap text onto separate lines - Increase font size to be closer to Qt - Remove extra letter spacing - 0.0 should use font default spacing, and this is used in `wrap_text` Will fix vertical alignment separately, as both the text and progress bar layouts need to be considered * ui(raylib): update spinner vertical pos (#35051) Adjust the spinner vertical position when displaying text or a progress bar - When displaying the progress bar, center the comma logo and spinner in the middle of the screen - When displaying text, center the entire content vertically Also updated `wrap_text` to not include an empty line in the array if it's the first line, so that `wrap_text("")` always returns `[]` * ui(raylib): "exit" btn in text window on PC (#35052) * ui(raylib): "exit" btn in text window on PC * unused import * Revert "ui(raylib): "exit" btn in text window on PC (#35052)" This reverts commit f9767d2. * plotjuggler: support relative paths (#35054) * Support relative paths * Abspath for rlog too * Reapply "ui(raylib): "exit" btn in text window on PC" (#35053) * ui(raylib): "exit" btn in text window on PC * unused import * request close * this was missing * Disable low speed steer in modeld (#35056) * disable low speed steer * No steer under * TOYOTA_RAV4_PRIME NNLC tuning gen 1 (#850) neural_network_data: TOYOTA_RAV4_PRIME NNLC tuning gen 1 * SL: updating localproxy implementation (#841) * Adding capabilities to route localProxy via sunnylink * Undo * Thx lint * get api token * cert is not valid when it's an IP. Still use cert, but don't validate * move to car_specific_sp * bump --------- Co-authored-by: Harald Schäfer <[email protected]> Co-authored-by: Kacper Rączy <[email protected]> Co-authored-by: Adeeb Shihadeh <[email protected]> Co-authored-by: Jason Wen <[email protected]> Co-authored-by: DevTekVE <[email protected]> Co-authored-by: Stupefacient <[email protected]> Co-authored-by: Alexandre Nobuharu Sato <[email protected]> Co-authored-by: commaci-public <[email protected]> Co-authored-by: Vehicle Researcher <[email protected]> Co-authored-by: programanichiro <[email protected]> Co-authored-by: eFini <[email protected]> Co-authored-by: Maxime Desroches <[email protected]> Co-authored-by: Shane Smiskol <[email protected]> Co-authored-by: Robbe Derks <[email protected]> Co-authored-by: Nayan <[email protected]> Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Cameron Clough <[email protected]> Co-authored-by: niko001 <[email protected]> Co-authored-by: Kumar <[email protected]> Co-authored-by: ZwX1616 <[email protected]> Co-authored-by: YassineYousfi <[email protected]> Co-authored-by: Tim Wilson <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Warren Togami <[email protected]> * fixing missing event * more event fixes * fixing spacing * more fixes * revert * update * update * update * reverting unneeded event * S P A C I N G * bumping opendbc * bump * Update sunnypilot/selfdrive/car/car_specific.py * Update sunnypilot/selfdrive/car/car_specific.py --------- Co-authored-by: Jason Wen <[email protected]> Co-authored-by: Harald Schäfer <[email protected]> Co-authored-by: Kacper Rączy <[email protected]> Co-authored-by: Adeeb Shihadeh <[email protected]> Co-authored-by: DevTekVE <[email protected]> Co-authored-by: Stupefacient <[email protected]> Co-authored-by: Alexandre Nobuharu Sato <[email protected]> Co-authored-by: commaci-public <[email protected]> Co-authored-by: Vehicle Researcher <[email protected]> Co-authored-by: programanichiro <[email protected]> Co-authored-by: eFini <[email protected]> Co-authored-by: Maxime Desroches <[email protected]> Co-authored-by: Shane Smiskol <[email protected]> Co-authored-by: Robbe Derks <[email protected]> Co-authored-by: Nayan <[email protected]> Co-authored-by: Discountchubbs <[email protected]> Co-authored-by: Cameron Clough <[email protected]> Co-authored-by: niko001 <[email protected]> Co-authored-by: Kumar <[email protected]> Co-authored-by: ZwX1616 <[email protected]> Co-authored-by: YassineYousfi <[email protected]> Co-authored-by: Tim Wilson <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Warren Togami <[email protected]>
Trained on 2023 RAV4 Prime XSE running fuzzy TOYOTA_RAV4_TSS2_2022.json so you could consider this to be a more refined almost gen 2 tuning.
twilsonco's analysis: "But the eps torque model looks really good! Yours looks nearly identical [to TOYOTA_RAV4_TSS2_2022]. It has a subtler instantaneous lateral jerk response. More gradual instantaneous jerk response."
This confirms the new tuning despite generated independent inputs is close to its predecessor.
Drive Test results
Drive Testing Completed
Summary by Sourcery
Update neural network lateral control (NNLC) tuning for Toyota RAV4 Prime, refining the previous generation's model with improved torque and lateral control characteristics.
New Features:
Enhancements:
Tests: