Ejemplo n.º 1
0
def step1(**kwargs):
    """
    setup and run all lammps jobs
    """
    turn_knobs = OrderedDict(
        [
            ('STRUCTURES', structures),
            ('PAIR_STYLE', pair_styles),
            ('PAIR_COEFF', pair_coeff_files)
        ])
    # job directory and run settings
    job_dir = 'lammps_job'
    nprocs = 4
    nnodes = 1
    walltime = '00:15:00'
    mem = 200
    job_bin = '/home/km468/Software/lammps/src/lmp_ufhpc < inp'
    qadapter, job_cmd = get_run_cmmnd(nnodes=nnodes, nprocs=nprocs,
                                      walltime=walltime,
                                      job_bin=job_bin, mem=mem)
    checkpoint_files = []
    chkpt_file = 'step1.json'
    # setup calibration jobs and run
    cal = CalibrateLammps(parameters, turn_knobs=turn_knobs,
                          qadapter=qadapter, job_cmd=job_cmd,
                          job_dir=job_dir, is_matrix=True,
                          checkpoint_file=chkpt_file,
                          cal_logger=logger)
    cal.setup()
    cal.run()
    checkpoint_files.append(chkpt_file)
    return checkpoint_files
Ejemplo n.º 2
0
def step1(**kwargs):
    """
    setup and run all lammps jobs
    """
    turn_knobs = OrderedDict([('STRUCTURES', structures),
                              ('PAIR_STYLE', pair_styles),
                              ('PAIR_COEFF', pair_coeff_files)])
    # job directory and run settings
    job_dir = 'lammps_job'
    nprocs = 4
    nnodes = 1
    walltime = '00:15:00'
    mem = 200
    job_bin = '/home/km468/Software/lammps/src/lmp_ufhpc < inp'
    qadapter, job_cmd = get_run_cmmnd(nnodes=nnodes,
                                      nprocs=nprocs,
                                      walltime=walltime,
                                      job_bin=job_bin,
                                      mem=mem)
    checkpoint_files = []
    chkpt_file = 'step1.json'
    # setup calibration jobs and run
    cal = CalibrateLammps(parameters,
                          turn_knobs=turn_knobs,
                          qadapter=qadapter,
                          job_cmd=job_cmd,
                          job_dir=job_dir,
                          is_matrix=True,
                          checkpoint_file=chkpt_file,
                          cal_logger=logger)
    cal.setup()
    cal.run()
    checkpoint_files.append(chkpt_file)
    return checkpoint_files
Ejemplo n.º 3
0
              'fix': ['fix_nve all nve',
                      '1 all box/relax aniso 0.0 vmax 0.001',
                      '1a all qeq/comb 1 0.0001 file fq.out']}
# list of pair styles
pair_styles = ['comb3 polar_off']
# list of pair coefficient files
pair_coeff_files = [os.path.join(os.getcwd(), "ffield.comb3")]
# parameters tuned: structures, pair styles and  pair coefficients
turn_knobs = OrderedDict(
    [
        ('STRUCTURES', structures),
        ('PAIR_STYLES', pair_styles),
        ('PAIR_COEFFS', pair_coeff_files)
    ])
# job directory and run settings
job_dir = 'lammps_job'
nprocs = 4
nnodes = 1
walltime = '00:15:00'
mem = 500
job_bin = '/home/km468/Software/lammps/src/lmp_ufhpc < inp'
qadapter, job_cmd = get_run_cmmnd(nnodes=nnodes, nprocs=nprocs,
                                  walltime=walltime,
                                  job_bin=job_bin, mem=mem)
# setup calibration jobs and run
cal = CalibrateLammps(parameters, turn_knobs=turn_knobs,
                      qadapter=qadapter, job_cmd=job_cmd,
                      job_dir=job_dir)
cal.setup()
cal.run()
Ejemplo n.º 4
0
    ]
}
# list of pair styles
pair_styles = ['comb3 polar_off']
# list of pair coefficient files
pair_coeff_files = [os.path.join(os.getcwd(), "ffield.comb3")]
# parameters tuned: structures, pair styles and  pair coefficients
turn_knobs = OrderedDict([('STRUCTURES', structures),
                          ('PAIR_STYLES', pair_styles),
                          ('PAIR_COEFFS', pair_coeff_files)])
# job directory and run settings
job_dir = 'lammps_job'
nprocs = 4
nnodes = 1
walltime = '00:15:00'
mem = 500
job_bin = '/home/km468/Software/lammps/src/lmp_ufhpc < inp'
qadapter, job_cmd = get_run_cmmnd(nnodes=nnodes,
                                  nprocs=nprocs,
                                  walltime=walltime,
                                  job_bin=job_bin,
                                  mem=mem)
# setup calibration jobs and run
cal = CalibrateLammps(parameters,
                      turn_knobs=turn_knobs,
                      qadapter=qadapter,
                      job_cmd=job_cmd,
                      job_dir=job_dir)
cal.setup()
cal.run()