mirror of
https://github.com/WallabyLester/RBF-aPID-Controller.git
synced 2026-05-13 08:00:06 +08:00
Implemented weight setter.
This commit is contained in:
@@ -81,3 +81,10 @@ double RBFModel::get_weight(int index) const {
|
||||
return weights[index];
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Set the weight at a specific index.
|
||||
*/
|
||||
void RBFModel::set_weight(int index, double value) {
|
||||
if (index < 0 || index >= numCenters) return;
|
||||
weights[index] = value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user