1 year ago
#360852
giovasbr
Training a machine learn model with more than one file
I'm kind of new in working with deep learning, and specially with more than one file per time. I have a folder of files, and I want that my model(LSTM) files train with all that files.
Can I just use model.fit() inside a loop of a path files? Would it make sense? Or I should try to concatenate that into a single array? In this case the problem is the features have different ranges.
import os
rootdir = '/content/Data' #looping over files
for filename in os.listdir('/content/Data'):
with open(os.path.join(rootdir, filename)) as f:
A = np.loadtxt(f) model.fit(x_train, y_train, batch_size=50,
epochs=20, shuffle=True)
python
keras
training-data
0 Answers
Your Answer