def METHOD_NAME(args):
    results_dir = "./results"
    if not os.path.exists(results_dir):
        os.makedirs(results_dir)
    device = args.device
    if args.method == 'pstgcn':
        print(f"==== Benchmarking pstgcn ({args.dataset_name}) ====")
        if args.dataset_name == 'nturgbd_cv':
            learner = ProgressiveSpatioTemporalGCNLearner(device=args.device, dataset_name='nturgbd_cv',
                                                          topology=[5, 4, 5, 2, 3, 4, 3, 4], in_channels=3,
                                                          num_point=25, graph_type='ntu')
        elif args.dataset_name == 'nturgbd_cs':
            learner = ProgressiveSpatioTemporalGCNLearner(device=args.device, dataset_name='nturgbd_cs',
                                                          topology=[5, 4, 3, 5, 3, 5, 7, 4], in_channels=3,
                                                          num_point=25, graph_type='ntu')
    else:
        print(f"==== Benchmarking {args.method} ({args.dataset_name}) ====")
        learner = SpatioTemporalGCNLearner(device=args.device, dataset_name='nturgbd_cv',
                                           method_name=args.method, in_channels=3, num_point=25,
                                           graph_type='ntu', num_class=60, num_subframes=100)
    learner.init_model()
    if args.device == 'cuda':
        learner.model.cuda()
    batch_size = 1
    num_runs = 100
    C = 3
    T = 300
    V = 25
    M = 2
    data = torch.randn(batch_size, C, T, V, M)
    samples = data
    def get_device_fn(*args):
        nonlocal learner
        return next(learner.model.parameters()).device
    def transfer_to_device_fn(sample, device,):
        return sample
    print("== Benchmarking learner.infer ==")
    results1 = benchmark(model=learner.infer,
                         sample=samples,
                         sample_with_batch_size1=None,
                         num_runs=num_runs,
                         get_device_fn=get_device_fn,
                         transfer_to_device_fn=transfer_to_device_fn,
                         batch_size=batch_size,
                         print_fn=print,
                         )
    with open(results_dir + f"/benchmark_{args.method}_{device}.txt", "a") as f:
        print("== Benchmarking learner.infer ==", file=f)
        print(yaml.dump({"learner.infer": results1}), file=f)
        print("\n\n", file=f)
        print("== Benchmarking model directly ==", file=f)
        results2 = benchmark(learner.model, data, num_runs=num_runs, print_fn=print)
        print(yaml.dump({"learner.model.forward": results2}))