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
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 Center 및 File Exchange에서 Regression에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!