Skip to content

Add zorrobyte's curvature learner modified to use dPoly curvature instead of angle, with more learning factors#223

Closed
sshane wants to merge 2 commits intostock_additions-077from
curv-learner
Closed

Add zorrobyte's curvature learner modified to use dPoly curvature instead of angle, with more learning factors#223
sshane wants to merge 2 commits intostock_additions-077from
curv-learner

Conversation

@sshane
Copy link
Owner

@sshane sshane commented Sep 14, 2020

  • Uses dPoly instead of angle steers to fix steering oscillation introduced by direction factor
  • New factors to learn:
    • Add direction
    • Add speed:
      • slow: up to 35 mph
      • medium: up to 55 mph
      • fast: inf
    • Add one more angle/curvature band:
      • center: up to 2.5° curvature equivalent
      • inner: up to 7.5° curvature equivalent
      • outer: up to 15.° curvature equivalent
      • sharp: up to inf° curvature equivalent

sshane and others added 2 commits September 14, 2020 14:24
* Add curvature learner atop latest stock_additions

* Clean up curvature learner, define values in dicts

* does this add or replace?

* add more of my data

* new tune, branch should be working now

* rearrange

* Up write freq

* new tune, increase lr, and use curvature from start of path not car

* tune curvature bands thanks to trae! slightly less variance

* make abs

* this was most common for outer

* add kmeans clustering test file

* update

* fix all zeros

* add more data from trae!

* clean up cluster_curvature

* add version and test file

* fix scaling factor

* add new clustering to curvature_learner.py

* rewrite file if version is newer than current version

* debugging

* temp fix

* temp fix

* fix

* revert, ready to test!

* add more of trae's data

* multiply cluster y coords by factor, don't need to keep doing it every loop

* rename

* add timing

* measure one second

* measure one second

* measure one second

* revert

* use list instead of dict

* switching to list gave us about 5% speed increase! some clean up

* lower min lr prob

* clean up

* speed up learning rate

* refactor

* clean up

* remove old file

* Revert "remove old file"

This reverts commit aff8cec.

* Add more data!

* refactor cluster_curvature a bit

* 1 more cluster for low speed, more y weight

* update version and clusters

* Revert INDI Prius Values (#163)

* add Curvature Learner to readme

* update readme

* add cluster image

* fix

* fix

* fix

* center

* Update README.md

* Update README.md

* update intro text!

* add more info to features section

* update wording

* Add fast learning. each cluster in each direction gets ~2.3 minutes of 5x learning speed

* bump version

* create a folder for curvature_learner

* remove old file

* remove old file

* lower learning rate and multiplier

* tune clusters and fast learning rate

* add more data!

* some clean up and comments

* only calculate abs(lat_pos) once, move direction calc to cluster_sample

* move function under update

* bump version

* remove comment

* one less cluster

* bump version

* 30 -> 20 min

* bump version

* tune clusters and 90 seconds per cluster. up min curvature

* fix y axis factor

* separate file to keep the offset file clean, add a param to toggle curv-learner on and off

* tune clusters and add cluster names back, strip leading and trailing 0's

* whoops

* another fix!

* back to known good

* add distplot for min_angle as a curvature

* Force battery temperature to 0 on comma two (#165)

* copy with same name as old just to diffs are easier

* revert some settings to August 11th

* revert fast learning rate for now

* faster lr

* comment out fast learning for now

* switch in curvature learner reverted to be similar to August 11th

* bump version

* move out

* remove for now

* add a file to verify my logic is good

* tune clusters and y axis factor

* slower learning

* fully revert to original learning rate

* tune clusters and debug

* bump version

* debug

* debug

* Debug

* Temp

* add debugging options

* Make live

* Tune

* add straight line data

* remove

* some param tuning for cluster_curvature.py

* add center band/cluster. cluster will never be None

* bump version

* Disable center

* Lower learning rate

* remove center cluster

* move lr_prob back

* revert

* revert

* ensure float

* use old planner code to calculate true curvature of poly

* don't eval poly for direction detection and enable debugging

* remove debugging

* remove

* fix

* Tune

* Tune

* add direction

* the logic is correct, idk why it's oscillating

* remove lr_prob restriction to test

* just so it's easier to read while debugging. positive values make it steer more!

* use angle_steers since that will reduce likelihood of mistakes in calculating direction from curvature

* fix

* fix

* revert readme

* revert opparams

* revert indi tuning

Co-authored-by: d412k5t412 <36134180+d412k5t412@users.noreply.github.com>
@sshane sshane marked this pull request as draft October 27, 2020 02:47
@sshane sshane force-pushed the stock_additions branch 2 times, most recently from 943b846 to 361bb45 Compare October 30, 2020 23:27
@sshane sshane closed this Nov 9, 2020
@sshane sshane reopened this Nov 9, 2020
@sshane sshane changed the base branch from stock_additions to stock_additions-077 November 9, 2020 20:29
@sshane sshane closed this Jan 22, 2021
@sshane sshane deleted the curv-learner branch January 22, 2021 17:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant