Hi Karsten!



 Karsten:

Thank you very much Frank,
I optimized the hidden layers as mentioned. But how can I prevent overfitting? And how do you differentiate between training data sets and accuracy data sets? My approach would be as follows:
import numpy as np


def train_test_split(M):
    train_data = M[:round(len(M)*0.8)]
    test_data = M[:round(len(M)*0.2)]
    return train_data, test_data



As far as your data splitting goes, you should try what you have
and see.  Take a look at your split data and see if it makes sense
to you.
(Hint:  Your code will use the first 80% of your data for training,
and the first 20% of your data for testing.  So your testing data
will be included in your training, and that isn’t really what you
want.)
It’s hard to say about over-fitting.  You haven’t really shared
anything with us about the actual structure of your data, so
it’s hard to have any intuition about your problem.
I still think you should make plots of your loss function and
accuracy for both your training and validation data.  What might
those plots look like, and what might they tell you (and us)?
Best.
K. Frank