(model, X_train, y_train, X_val, y_val, ctable)
Iterative Training
Iterative Training
Iterative Training
def iterate_training(model, X_train, y_train, X_val, y_val, ctable):
    """Iterative Training"""
    # Train the model each generation and show predictions against the validation dataset
    for iteration in range(1, CONFIG.number_of_iterations):
        print()
        print('-' * 50)
        print('Iteration', iteration)
        model.fit(X_train, y_train, batch_size=CONFIG.batch_size, epochs=CONFIG.epochs,
                  validation_data=(X_val, y_val))
        print_random_predictions(model, ctable, X_val, y_val)
def iterate_training ( model , X_train , y_train , X_val , y_val , ctable ) : # Train the model each generation and show predictions against the validation dataset for iteration in range ( 1 , CONFIG . number_of_iterations ) : print ( ) print ( '-' * 50 ) print ( 'Iteration' , iteration ) model . fit ( X_train , y_train , batch_size = CONFIG . batch_size , epochs = CONFIG . epochs , validation_data = ( X_val , y_val ) ) print_random_predictions ( model , ctable , X_val , y_val )