示例#1
0
def create_sg_assemble_model(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""

    gtinitmodel = GtInitModel()
    init_link = gtinitmodel.link

    gtassemble = GtAssembleModel(**kwargs)
    link = gtassemble.link


    appname = kwargs.pop('appname', 'fermipy-assemble-model-sg')

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Copy source maps from the library to a analysis directory"

    config_maker = ConfigMaker_AssembleModel(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                initialize=init_link,
                                **kwargs)
    return lsf_sg
示例#2
0
def create_sg_assemble_model(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""

    gtinitmodel = GtInitModel()
    init_link = gtinitmodel

    gtassemble = GtAssembleModel(**kwargs)
    link = gtassemble

    appname = kwargs.pop('appname', 'fermipy-assemble-model-sg')

    lsf_args = {'W': 1500, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Copy source maps from the library to a analysis directory"

    config_maker = ConfigMaker_AssembleModel(link)
    lsf_sg = build_sg_from_link(link,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                initialize=init_link,
                                **kwargs)
    return lsf_sg
示例#3
0
def create_sg_merge_srcmaps(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""
    gtmerge = GtMergeSourceMaps()
    link = gtmerge.link
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'fermipy-merge-srcmaps-sg')

    lsf_args = {'W': 6000,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Prepare data for diffuse all-sky analysis"

    config_maker = ConfigMaker_MergeSrcmaps(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#4
0
def create_sg_srcmap_partial(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""
    gtsmp = GtSrcmapPartial()
    link = gtsmp.link
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'fermipy-srcmaps-diffuse-sg')

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Build source maps for diffuse model components"

    config_maker = ConfigMaker_SrcmapPartial(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#5
0
def create_sg_plot_dm(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""

    link = CastroPlotterDM(**kwargs)
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'dmpipe-plot-dm-sg')

    lsf_args = {'W': 50, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Make castro plots for set of targets"

    config_maker = ConfigMaker_PlotCastroDM(link)
    lsf_sg = build_sg_from_link(link,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#6
0
def create_sg_gtsrcmaps_catalog(**kwargs):
    """Build and return a ScatterGather object that can invoke gtsrcmaps for catalog sources"""
    appname = kwargs.pop('appname', 'fermipy-srcmaps-catalog-sg')
    link = create_link_gtscrmaps(**kwargs)
    linkname = kwargs.pop('linkname', link.linkname)

    lsf_args = {'W': 6000, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Run gtsrcmaps for catalog sources"

    config_maker = ConfigMaker_SrcmapsCatalog(link)
    lsf_sg = build_sg_from_link(link,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#7
0
def create_sg_gtsrcmaps_catalog(**kwargs):
    """Build and return a ScatterGather object that can invoke gtsrcmaps for catalog sources"""
    appname = kwargs.pop('appname', 'fermipy-srcmaps-catalog-sg')
    link = create_link_gtscrmaps(**kwargs)
    linkname=kwargs.pop('linkname', link.linkname)

    lsf_args = {'W': 6000,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Run gtsrcmaps for catalog sources"

    config_maker = ConfigMaker_SrcmapsCatalog(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#8
0
def create_sg_healview_diffuse(**kwargs):
    """Build and return a ScatterGather object that can invoke fermipy-healview"""
    appname = kwargs.pop('appname', 'fermipy-healview-sg')
    link = create_link_fermipy_healview(**kwargs)
    linkname = kwargs.pop('linkname', link.linkname)

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Sum gasmaps to build diffuse model components"

    config_maker = ConfigMaker_healview(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#9
0
def create_sg_Gtsuntemp(**kwargs):
    """Build and return a ScatterGather object that can invoke gtexphpsun"""
    appname = kwargs.pop('appname', 'fermipy-gtsuntemp-sg')
    link = create_link_gtsuntemp(**kwargs)
    linkname = kwargs.pop('linkname', link.linkname)

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Run gtexpcube2 for a series of event types."

    config_maker = ConfigMaker_Gtsuntemp(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#10
0
def create_sg_gtexpcube2(**kwargs):
    """Build and return a ScatterGather object that can invoke gtexpcube2"""
    appname = kwargs.pop('appname', 'fermipy-gtexcube2-sg')
    link = create_link_gtexpcube2(**kwargs)
    linkname = kwargs.pop('linkname', link.linkname)

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Run gtexpcube2 for a series of event types."

    config_maker = ConfigMaker_Gtexpcube2(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#11
0
def create_sg_sed_analysis(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""
    sed_analysis = SEDAnalysis(**kwargs)
    link = sed_analysis
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'dmpipe-analyze-sed-sg')

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Run analyses on a series of ROIs"

    config_maker = ConfigMaker_SEDAnalysis(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#12
0
def create_sg_healview_diffuse(**kwargs):
    """Build and return a ScatterGather object that can invoke fermipy-healview"""
    appname = kwargs.pop('appname', 'fermipy-healview-sg')
    link = create_link_fermipy_healview(**kwargs)
    linkname = kwargs.pop('linkname', link.linkname)

    lsf_args = {'W': 1500, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Sum gasmaps to build diffuse model components"

    config_maker = ConfigMaker_healview(link)
    lsf_sg = build_sg_from_link(link,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#13
0
def create_sg_castro_convertor(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""
    castro_convertor = DMCastroConvertor(**kwargs)
    link = castro_convertor
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'dmpipe-convert-castro-sg')

    lsf_args = {'W': 1500, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Convert SEDs to DMCastroData objects"

    config_maker = ConfigMaker_CastroConvertor(link)
    lsf_sg = build_sg_from_link(link,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#14
0
def create_sg_merge_srcmaps(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""
    gtmerge = GtMergeSourceMaps()
    link = gtmerge.link
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'fermipy-merge-srcmaps-sg')

    lsf_args = {'W': 6000, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Prepare data for diffuse all-sky analysis"

    config_maker = ConfigMaker_MergeSrcmaps(link)
    lsf_sg = build_sg_from_link(link,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#15
0
def create_sg_residual_cr(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""
    analyzer = ResidualCRAnalysis()
    link = analyzer.link
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'gt-residual-cr-sg')

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Copy source maps from the library to a analysis directory"

    config_maker = ConfigMaker_ResidualCR(link)
    lsf_sg = build_sg_from_link(link, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=link.linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#16
0
def create_sg_srcmap_partial(**kwargs):
    """Build and return a ScatterGather object that can invoke this script"""
    gtsmp = GtSrcmapPartial(**kwargs)
    link = gtsmp
    link.linkname = kwargs.pop('linkname', link.linkname)
    appname = kwargs.pop('appname', 'fermipy-srcmaps-diffuse-sg')

    lsf_args = {'W': 1500, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Build source maps for diffuse model components"

    config_maker = ConfigMaker_SrcmapPartial(link)
    lsf_sg = build_sg_from_link(link,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                linkname=link.linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#17
0
def create_sg_split_and_mktime(**kwargs):
    """Build and return a `fermipy.jobs.ScatterGather` object that can invoke this script"""
    linkname = kwargs.pop('linkname', 'split-and-mktime')
    chain = SplitAndMktime(linkname, **kwargs)
    gather = CoaddSplit('%s.coadd' % linkname, **kwargs)
    appname = kwargs.pop('appname', 'fermipy-split-and-mktime-sg')

    lsf_args = {'W': 1500, 'R': 'rhel60'}

    usage = "%s [options]" % (appname)
    description = "Prepare data for diffuse all-sky analysis"

    config_maker = ConfigMaker_SplitAndMktime(chain, gather)
    lsf_sg = build_sg_from_link(chain,
                                config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                gather=gather,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg
示例#18
0
def create_sg_split_and_bin(**kwargs):
    """Build and return a `fermipy.jobs.ScatterGather` object that can invoke this script"""
    linkname = kwargs.pop('linkname', 'split-and-bin')
    chain = SplitAndBin('%s.split'%linkname)
    gather = CoaddSplit('%s.coadd'%linkname)
    appname = kwargs.pop('appname', 'fermipy-split-and-bin-sg')

    lsf_args = {'W': 1500,
                'R': 'rhel60'}

    usage = "%s [options]"%(appname)
    description = "Prepare data for diffuse all-sky analysis"

    config_maker = ConfigMaker_SplitAndBin(chain, gather)
    lsf_sg = build_sg_from_link(chain, config_maker,
                                lsf_args=lsf_args,
                                usage=usage,
                                description=description,
                                gather=gather,
                                linkname=linkname,
                                appname=appname,
                                **kwargs)
    return lsf_sg