BYU-PRISM / Seeq

Hybrid (Physics-Informed) Machine Learning
MIT License
44 stars 5 forks source link

Transfer Function Model Identification Questions #49

Open vickieyc opened 11 months ago

vickieyc commented 11 months ago

Hello,

Thank you very much for creating this really great add-on for system identification!

I recently started working with the transfer function identification and I understand sometime there is no solution since it is a physics informed model based on FOPDT/SOPDT model. However, I frequently get the "no solution found" message for some of the processes; while in comparison, Matlab system identification tool almost always gives an result, even though the fitting may be like ~70%.

I am wondering if you could suggest some of ways that can find the "not so perfect" solution. I have tried a couple things listed below:

(1) Providing ub and lb for the model - I put the Matlab result (+/- 10%) as ub and lb for the transfer model set up. (2) Modifying the Gekko solver - I increased the MAXITER and MAX_TIME to a higher value. I did notice that the time for the no solution card show up was like 2s, way shorter than 1800s defined in the program. Is there a flag for the solver to exit early? (3) Cropping the dataset to only the step change portion or different combination of step changes/no process change. Would there be an ideal number of step changes/time period for the solver?

Not sure if it is just because I have "difficult" data, but these did not help to find the solution. Is there a way that the convergence criteria can be relaxed? I understand that KKT conditions are not met indicating that the global minimum to this optimization problem is not found, but this is more like a parameter fitting instead of optimization problem - as such, a saddle point solution which gives a decent fit to the process may still be useful. Additionally, would changing the imode to sequential estimation (8) help for this case?

Sorry for asking so many questions in the issues section. Thanks in advance for your help!

ysghandi commented 1 month ago

Hello,

I have the same issue too. Could you share how I can modify the Gekko solver in this Seeq Add-on?

imanbabaei commented 1 month ago

Hi @vickieyc , Thank you for your feedback.

I also realized the issue with tf identification. I need to run the code and check the solver report. Returning a solution in any case is one of the things i want to see in the new updates.

@ysghandi , TransferItem is a GEKKO subclass. You can modify it based on gekko docs.