# How to approach data prediction problem

I'm new to ML and data science. I would really like high level advice how to approach the following problem. I need to predict if an engine will fail, what I've is a sensor that give a certain value between 1 to 4 so a record might look like:

1243412312431444123123234234232423


Each record is 150 readings in length. I've a few millions of this records but in no particular order (i.e. the database doesn't contain explicit timestamp although by using some quirk database artifact I can make some records appear in order)

I've 200 different engines and a label of "failed" and "active" for each one.

So I'm looking for a predictive model that can predict (or detect) using the above data whether an engine failed or not. Any advice?

Thanks, Eden

• So these are sequential readings from a sensor, but an engine's 150-vectors are not in any particular order, thus time-series approaches cannot be applied. You could treat it as anomaly detection but in general there should be a more detailed/better-structured problem statement for the algorithm to detect an existing pattern (not regarding your description but the overall problem definition). Therefore this might be a detection rather than a prediction issue. Sep 26, 2019 at 8:04
• If my understanding is correct, then the data does have labels. Thus you can try to learn the labels and predict them ('failed' or 'active'). Note that there is no guarante that they are differentiable. If you can get the dataset before the failure, then you can try to predict it. If they are not labeled, follow @Nicos advice. Sep 26, 2019 at 8:13
• @Nikos - Thank. Assuming I'm going the detection route as you suggested. How to approach it?
– Eden
Sep 26, 2019 at 9:24
• seems to me like a binary classification problem. Have you tried logistic regression?
– mnm
Feb 23, 2020 at 14:29
• So you have 200 labels - one for each engine? And for each engine there are 150 sample sub-sequences representing some state at a point in time - but you cannot reconstruct the original sequence? Oct 21, 2020 at 2:49

Are you familiar with deep learning? If yes, I would advise you to one-hot encode these records and use a 2D convolutional neural network for prediction. Since these are mere numbers and there is no way to engineer new features, I'm afraid conventional ML methods won't work. And the records have only 4 unique values, so 2D-Convolutional NN can handle it. Treat them as a picture and let the NN capture the patterns and predict the result.

Best of Luck, Eden.

• I'm not sure how 2D-Convolutional NN can handle it? Any record is randomly placed next to another record. I.e. there is no feature to extract from placing 2 records next to each other in the image.
– Eden
Sep 26, 2019 at 9:27

First you have to understand what are those records. What is the mean of each number from the sensor. If the order of each number is useful or useless. Then, you have to determine the number of input you've got, and how to make them more comprehensive. And then, you've got to build a classification. But, in those kind of case, I think it would be imbalanced.

The first fast approach I'would do, is to test with pycaret some vanilla models, and try some scenarii.

Then, I would prepare a real one, fixing first the problem of balance.

Don't go too fast with ML or DL, because, if you don't exactly know what is the problem you wanna solve, it will be hard.

It's a good challenge. If you have more data to share, it will perhaps be easier to explain.

Happy coding.