* refactor: move lateral methods from init to lateral.py (#2594)
* Extracting lateral methods to lateral.py
* cleaning
* more cleaning
* more cleaning
* Making sure it remains where it should
* Leave rate_limit where it belongs
* Moving things to `car/controls/`
* Moving rate limit to get a taste of the changes
* clean
* copy verbatim
* clean up
* more
* now we can format
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* No need to change order of import
* refactor: consolidate ACCELERATION_DUE_TO_GRAVITY import path
* bump opendbc
* update refs
* don't import from opendbc
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* stash
* Revert "stash"
This reverts commit 333818b80f.
* works for paramsd
* INSANE
* format
* fater
* clean up
* more
* huh i thought order matterred?
* clean that up
* can remove this
* cmt
* check isisntance
* rename
* clean up
* clean up
* more
* more!
* sounds better
* save 1-2s for full route
* now more than halve the time on top of previous speedup!
* stash
* default should be most common!
* revert
* revert
* clean up
* clean up
* clean up
* clean up
* format
* containers might not be set
* opts
* halves startup time for 12 procs (1.6 to 0.8s)
* stash
* clean up
* who knew going through entire list of msgs each time is so slow
* rewrite this to be more readable
* speed up lr
* clean up
* more
* more
* format
* containers might not be set
* opts
* halves startup time for 12 procs (1.6 to 0.8s)
* stash
* Revert "stash"
This reverts commit 3e119a9602.
* Revert "halves startup time for 12 procs (1.6 to 0.8s)"
This reverts commit a39edf0a57.
* Revert "opts"
This reverts commit 4dc1f75f09.
* already set!
* holy shit
* benchmark without this main pub drain stuff
* revert
* ??
* actually this is what we want
* what is going on this is python 3.11 sir
* stash
* this is how you dew it
* minor clean up
* fix
* clean up
* clean up
* this is madness!
* typing
* clean up
* Use in modeld
* Use in torqued
* Do not use default value in torqued
* Add liveDelay in process replay
* update ref
---------
Co-authored-by: Bruce Wayne <harald.the.engineer@gmail.com>
* now alpha long
* fix
* rename param
* thought i did this
* debug
* debug
* more
* more
* moar
* Revert "moar"
This reverts commit e347106246.
* Revert "more"
This reverts commit 0746e6d2e4.
* Revert "more"
This reverts commit 0db5a8792c.
* Revert "debug"
This reverts commit 72f235b137.
* Revert "debug"
This reverts commit 7871b69f8c.
* Online lateral lag learning (#34974)
This reverts commit b4cc9e68d1.
* 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
* Add struct and services
* Proof of concept
* Use vego
* Process replay support
* Fix issues
* Max not min
* Remove print
* Make lag positive
* Points and updates
* Sliding cross corr
* Stuff
* Remove redundant param
* Move to lagd
* Update alert
* Something that works
* Report isEstimated
* Corr field
* Use skimage masked corr
* Fixes
* Move to lat_accel_loc
* Use the delay it in the model
* Mark as executable
* Add 0.2 to initial
* add install line
* Back to 5m window
* Move the import up
* corr window 120
* Show is estimated
* Sort messages
* New impl
* Fix
* Params
* Set initial_lag elsewhere
* Add param
* Rename Param
* Fix type isues
* More blocks
* Masked fft NCC implementation
* Remove package installation
* Use 20hz data and interp the correlation peak
* Move ncc code to separate function
* steering_saturated support
* Constants
* Add recovery buffer
* Fix static
* min_valid_block_count nad liveDelay
* lateralDelayEstimate
* Fix comm issues. Do estimations at 4hz
* Fix
* Display the estimate
* Increase the block size
* Cache every minute
* DEBUG flag
* Add progress to the alert
* Fix crash
* points only in debug
* Fix BlockAverage restoration
* Comment
* Move estimators into estimator directory
* Remove lagd
* Feed only relevant messages
* Rewrite as a set literal
* np.diag with P_initial
* Fix static
* Struct renames
* Update ref commit
* Make it nicer
* Some renames
* Refactor ParamsLearner
* Make it VehicleParamsLearner
* Fix
* Use capnp serialization instead of json
* Fix speed
* Remove redundant comments
* Monitor observed_roll
* Just use init_state
* Comment
* Improve reset
* Set globals api
* Typing for return value
* Redo reset messaging
* Remove usages of math
* Fix process_replay custom_params
* Type ignores for rednose fields
* Remove import
* Reset previous values too
* Update ref_commit
* Revert it
* Bring it back
* Remove more
* Add migration for cached params
* No /dev/shm on MacOS so we go to tmp instead given that the /dev/shm makes tests not really work fine on mac
* Cleanups
Fix cereal messaging tests
* keep msgq stock
More shm updates for macos
* typo
* fix return
* Semicolon...
* long planner: use vehicle model w/ avg steer offset for limit accel in turns
* remove unused CP in limit_accel_in_turns
* revert use of vehicle model, keeping angle offset in limit accel in turns
* only the offset fix, check valid, and fix process replay
* update refs (valid two frames later)
---------
Co-authored-by: Shane Smiskol <shane@smiskol.com>
* test selfdrived!
* exit() is for interactive sessions
* fix
* comments
* more
* test all of selfdrive/
* ignore what we used to
* fix test_alerts
* fix test_alertmanager.py
* Reapply "move car.capnp to opendbc" (#33725)
This reverts commit 9d52a5b485.
* why can't i repro?!
* Revert "why can't i repro?!"
This reverts commit 0435d218f7.
* does this cause card to try and read it?
* better place
* wtf
* Reapply "why can't i repro?!"
This reverts commit d24fd5a0ab.
* also here
* Add model execution time to DrivingModelData
* Update model replay ref commit
* Update ref commit again
* Ignore this field in model replay
* Back to original ref commit
* Bring back
---------
Co-authored-by: Comma Device <device@comma.ai>
* interfaces returns radarinterface
old-commit-hash: 9ad1f096bf
* bump
old-commit-hash: 20334a8b25
* get RI from opendbc
old-commit-hash: b5f6d0c48c90927926e9dd557130075aeec5edee
* stash so far
old-commit-hash: 5aa2c842eb152316434c17a661df05bb8af61f47
* new liveTracks message (radard expects and needs RadarData)
* this should just work?
* whoops
* fix that
* rm liveTracks from radard pm
* fix proceess replay
* lol fcw diff, something's not right
* actually there's fcw in original route. it's pretty close
* no tracks!
* fix test_leads
* CPU moved across procs
* fix not engageable from onroadEvents
* bump
* fixes
* bump to master
* radard publishes w/ modelV2 now, so it will always be sent. check valid which radard sets using liveTracks avg freq
* fix that (it works!)
* combine
join
* bump
* bump
* deprecate
* why
* fix incorrect args
* remove cumLagMs from process_replay
* update refs