示例#1
0
def _parse_args():
    parser = baseparsers.make_parser("uc_cylinders")
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.fixer_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.lagrangian_args(parser)
    parser = baseparsers.xhatlooper_args(parser)
    parser = baseparsers.xhatshuffle_args(parser)
    parser = baseparsers.cross_scenario_cuts_args(parser)
    parser.add_argument("--ph-mipgaps-json",
                        help="json file with mipgap schedule (default None)",
                        dest="ph_mipgaps_json",
                        type=str,
                        default=None)
    parser.add_argument("--solution-dir",
                        help="writes a tree solution to the provided directory"
                             " (default None)",
                        dest="solution_dir",
                        type=str,
                        default=None)
    parser.add_argument("--xhat-closest-tree",
                        help="Uses XhatClosest to compute a tree solution after"
                             " PH termination (default False)",
                        action='store_true',
                        dest='xhat_closest_tree',
                        default=False)
    args = parser.parse_args()
    return args
示例#2
0
def _parse_args():
    parser = baseparsers.make_parser()
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.mip_options(parser)
    parser = baseparsers.fixer_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.lagrangian_args(parser)
    parser = baseparsers.xhatlooper_args(parser)
    parser = baseparsers.xhatshuffle_args(parser)
    args = parser.parse_args()
    return args
示例#3
0
def _parse_args():
    parser = baseparsers.make_parser(num_scens_reqd=False)
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.xhatlshaped_args(parser)
    args = parser.parse_args()
    # Need default_rho for FWPH, without you get
    # uninitialized numeric value error
    if args.with_fwph and args.default_rho is None:
        print("Must specify a default_rho if using FWPH")
        quit()

    return args
示例#4
0
def _parse_args():
    parser = baseparsers.make_parser(num_scens_reqd=True)
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.xhatlooper_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.lagranger_args(parser)
    parser = baseparsers.xhatshuffle_args(parser)
    parser.add_argument("--crops-mult",
                        help="There will be 3x this many crops (default 1)",
                        dest="crops_mult",
                        type=int,
                        default=1)                
    args = parser.parse_args()
    return args
示例#5
0
def _parse_args():
    parser = baseparsers.make_parser(num_scens_reqd=False)
    parser.add_argument("--instance-name",
                        help="sslp instance name (e.g., sslp_15_45_10)",
                        dest="instance_name",
                        type=str,
                        default=None)                
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.fixer_args(parser)
    parser = baseparsers.xhatlooper_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.lagrangian_args(parser)
    parser = baseparsers.xhatshuffle_args(parser)
    args = parser.parse_args()
    return args
示例#6
0
def _parse_args():
    parser = baseparsers.make_parser(num_scens_reqd=False)
    parser.add_argument("--instance-name",
                        help="netdes instance name (e.g., network-10-20-L-01)",
                        dest="instance_name",
                        type=str,
                        default=None)                
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.xhatlooper_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.lagrangian_args(parser)
    parser = baseparsers.xhatshuffle_args(parser)
    parser = baseparsers.slamup_args(parser)
    parser = baseparsers.cross_scenario_cuts_args(parser)
    args = parser.parse_args()
    return args
示例#7
0
def _parse_args():
    parser = baseparsers.make_parser("uc_cylinders")
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.fixer_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.lagrangian_args(parser)
    parser = baseparsers.xhatlooper_args(parser)
    parser = baseparsers.xhatshuffle_args(parser)
    parser.add_argument("--ph-mipgaps-json",
                        help="json file with mipgap schedule (default None)",
                        dest="ph_mipgaps_json",
                        type=str,
                        default=None)

    args = parser.parse_args()
    return args
def _parse_args():
    parser = baseparsers.make_parser(num_scens_reqd=True)
    parser = baseparsers.two_sided_args(parser)
    parser = baseparsers.fwph_args(parser)
    parser = baseparsers.xhatlshaped_args(parser)
    parser.add_argument("--crops-mult",
                        help="There will be 3x this many crops (default 1)",
                        dest="crops_mult",
                        type=int,
                        default=1)
    args = parser.parse_args()
    # Need default_rho for FWPH, without you get
    # uninitialized numeric value error
    if args.with_fwph and args.default_rho is None:
        print("Must specify a default_rho if using FWPH")
        quit()
    return args