Need Advice on How to input Machine Learning Prediction Function into Genetic Algorithm Fitness Function

1 次查看(过去 30 天)
Hello all,
First of all my way of constructive thinking might be wrong, so sorry if my title is misleading. Any advice is more than welcome.
My task is :I have a set of 50 GB data inputted and processed in Regression Learner (5 geometric variable, 1 physics score), what I actually want is by using 1 geometric variable and known specific score, I want to get remaning 4 geometric variable combination predictions. My score is not a linear acting score that changes systematically wrt geometry.
Since my input data is very large, I do not want to train my model more than once - and table indexing and interpolating takes too much time - I find trainedModel.predictFcn much more faster and reliable. I will also need to perform this many times so I have to create a structure to automate the prediction process.
What I thought : If I can somehow input "trainedModel.predictFcn" into GA fitness function, I can achive my task. Bu the main problem is ML prediction function accepts table as input (need to code as yfit=trainedModel.predictFcn(table)), and ga inputs vectors. If I create seperate fitness function script (that enables format conversion easily) I have to add RegressionModel training to fitness function, so Matlab will re-learn the data each time, and it will take tremendous time. Also I cant seperate learning function and trainedModel.predictFcn function to different scripts as they are interconnected.
So in short, I need to cache Reg. L. training, overcome the format errors and use prediction function as fitness function.
Thanks in advance for your suggestions.
Al.
  2 个评论
peyman zandi
peyman zandi 2022-1-30
Hi,
Before anything, Can you define your trained model as an objective function? (I mean your objective function is not like a regular mathematic formula and it looks like a predective GBM model for example)

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Regression 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by