def printParaNum(model):
    '\n    function: print the number of total parameters and trainable parameters\n    '
    total_params = sum((p.numel() for p in model.parameters()))
    total_trainable_params = sum((p.numel() for p in model.parameters() if p.requires_grad))
    print(('Total parameters: %d' % total_params))
    print(('Trainable parameters: %d' % total_trainable_params))
function: print the number of total parameters and trainable parameters
def printParaNum(model):
    '\n    \n    '
    total_params = sum((p.numel() for p in model.parameters()))
    total_trainable_params = sum((p.numel() for p in model.parameters() if p.requires_grad))
    print(('Total parameters: %d' % total_params))
    print(('Trainable parameters: %d' % total_trainable_params))