def METHOD_NAME(
        SCRIPFilenameSrc, SCRIPFilenameDst, weightsFilename, reuseWeights):
    if not reuseWeights or not os.path.isfile(weightsFilename):
        args = ["ESMF_RegridWeightGen",
                "--source", SCRIPFilenameSrc,
                "--destination", SCRIPFilenameDst,
                "--weight", weightsFilename,
                "--src_regional", "--dst_regional", "--ignore_unmapped"]
        subprocess.run(args, check=True)