def show_progress(epoch, step, n_epochs, n_steps, steps_in_epoch, loss):
    """
    print the current progress and loss
    :param epoch: current epoch
    :param step: current step
    :param n_epochs: number of epoch in training
    :param n_steps: number of steps in training
    :param steps_in_epoch: number of steps in one epoch
    :param loss: current loss
    """
    n_steps = n_steps if n_steps is not None else n_epochs * steps_in_epoch - 1
    steps_taken = epoch * steps_in_epoch + step
    progress = round(100 * steps_taken / n_steps, 2)
    print(
        f'\rprogress: {progress}%, epoch: {epoch}, step: {step}, loss: {loss}',
        end='')
