Utilities for:
- loading and processing tire test data
- plotting measured tire data together with the force model
- fitting a symbolic
mu(v)expression with Flex symbolic regression
src/sr_tire/process_data.py: load and split the tire datasetsrc/sr_tire/force.py: force-model implementationsrc/sr_tire/dynamic_pde/simulate_pde.py: JAX translation of the dynamic PDE simulationsrc/sr_tire/dynamic_pde/compare_pacejka.py: compare PDE forces against Pacejka datasrc/sr_tire/plot.py: plotting utilitiessrc/sr_tire/steady_stribeck/flex_sr_run.py: Flex symbolic regression entry pointsrc/sr_tire/steady_stribeck/config.yaml: Flex configurationdata/lateral_tire_test.csv: tire dataset
From the repo root:
python -m pip install -e .To plot the default force model against the processed tire data:
python -m sr_tire.plotTo run the dynamic PDE tire simulation:
python -m sr_tire.dynamic_pde.simulate_pdeThe module saves the bristle deformation, force, and slip plots under the
repository-root results/pde/. To open
interactive plot windows as well:
python -m sr_tire.dynamic_pde.simulate_pde --showTo save those figures programmatically:
from sr_tire.dynamic_pde.simulate_pde import plot_simulation, simulate_pde
result = simulate_pde()
plot_simulation(result, output_dir="results/pde", show=False)To run the equivalent dctkit cochain-based spatial discretization with Diffrax time integration:
python -m sr_tire.dynamic_pde.simulate_pde_dctkitTo compare the dynamic PDE forces with the comparable Pacejka force trajectory
in data/Fx_dataset.csv, using parameterization=1, excitation=var2,
run=5, sigma_0=0.12, amplitude ratio 0.4, and omega=10*pi:
python -m sr_tire.dynamic_pde.compare_pacejkaThis writes comparison plots and per-trajectory error metrics to the
repository-root results/pde/.
By default, the comparison plot shows that same var2, run 5 pair. To choose
another pair within parameterization=1:
python -m sr_tire.dynamic_pde.compare_pacejka --excitation var2 --run 1To run Flex SR for an additive term in the dynamic PDE right-hand side:
python -m sr_tire.dynamic_pde.flex_sr_runThe run is configured by src/sr_tire/dynamic_pde/config.yaml and scores each
candidate by solving the PDE and comparing the resulting force trajectory with
the selected trajectory from data/Fx_dataset.csv.
The default configuration is intentionally small so it can complete on modest
machines; increase num_individuals, generations, n_x, max_time_points,
and the PSO settings only after the smoke-sized run finishes.
To run a single training run without hyperparameter optimization:
python -m sr_tire.steady_stribeck.flex_sr_runTo run multiple independent training runs:
python -m sr_tire.steady_stribeck.flex_sr_run --num-runs 5To control the base random seed used for repeated runs:
python -m sr_tire.steady_stribeck.flex_sr_run --num-runs 5 --seed 123To run with Optuna HPO:
python -m sr_tire.steady_stribeck.flex_sr_run --hpoTo run random expression search with the same primitive set as Flex SR and a 7-minute wall-clock budget per run:
python -m sr_tire.steady_stribeck.random_search_runTo run multiple independent random-search runs:
python -m sr_tire.steady_stribeck.random_search_run --num-runs 5To change the per-run time budget:
python -m sr_tire.steady_stribeck.random_search_run --time-budget-seconds 420After running Flex SR, the script:
- prints dataset summary information
- fits the symbolic
mu(v)model - saves all steady Stribeck artifacts under:
results/steady-stribeck/
Flex SR writes:
results/steady-stribeck/best_model_results.txt
results/steady-stribeck/best_model_plot.png
results/steady-stribeck/best_mu_plot.png
results/steady-stribeck/flex_runs/
The random-search baseline writes analogous results to:
results/steady-stribeck/random_search_best_model_results.txt
results/steady-stribeck/random_search_best_model_plot.png
results/steady-stribeck/random_search_best_mu_plot.png
results/steady-stribeck/random_search_runs/
- The current dataset split is:
- bins 1-3: training
- bin 4: validation
- bin 5: test
- The CSV is loaded from
data/at the repo root.