示例#1
0
                message += "'snr_sum', 'snr_max'] instead."
                # --------------------------------------------------------------------------
                err.error(message, fatal=True, frame=True)

# ---------------------
# ---- IMPORT DATA ----
# ---------------------

err.print_progress_message("Loading data cube(s)", t0)
kwargs = Parameters["import"].copy()
kwargs.update({
    "doFlag": Parameters["steps"]["doFlag"],
    "flagRegions": Parameters["flag"]["regions"],
    "flagFile": Parameters["flag"]["file"]
})
np_Cube, dict_Header, mask, subcube = import_data.read_data(
    Parameters["steps"]["doSubcube"], **kwargs)
#np_Cube, dict_Header, mask, subcube = import_data_2.import_data(Parameters["steps"]["doSubcube"], **kwargs)
err.message("Data cube(s) loaded.")
if Parameters["pipeline"]["trackMemory"]: print_memory_usage(t0)

# -------------------------
# ---- PRECONDITIONING ----
# -------------------------

if Parameters["steps"]["doSmooth"] or Parameters["steps"][
        "doScaleNoise"] or Parameters["steps"]["doWavelet"]:
    err.print_progress_message("Applying input filters", t0)
    if Parameters["pipeline"]["trackMemory"]: print_memory_usage(t0)

# ---- SMOOTHING ----
if Parameters["steps"]["doSmooth"]:
示例#2
0
if((not outputDir) or (not os.path.isdir(outputDir)) or (outputDir.isspace())):
    outroot = Parameters['import']['inFile'][0:len(Parameters['import']['inFile'])-len(Parameters['import']['inFile'].split('/')[-1])]+outroot
else:
    if outputDir[-1] != '/': outputDir += '/'
    outroot = outputDir + outroot


# ---------------------
# ---- IMPORT DATA ----
# ---------------------

print "\n--- %.3f seconds since start"%(time()-t0)
print "\n--- SoFiA: Reading data cube(s) ---"
sys.stdout.flush()

np_Cube, dict_Header, mask, subcube = import_data.read_data(Parameters['steps']['doSubcube'],**Parameters['import'])


# -------------------------
# ---- PRECONDITIONING ----
# -------------------------

print "\n--- %.3f seconds since start"%(time()-t0)
print "\n--- SoFiA: Running input filters ---"
sys.stdout.flush()

# ---- FLAGGING ----
if Parameters['steps']['doFlag']:
	np_Cube = flag_cube.flag(np_Cube,**Parameters['flag'])

# ---- SMOOTHING ----
示例#3
0
				message += "future once the linker has been fixed. For the time being we\n"
				message += "recommend using the default parameter space of ['snr_mean',\n"
				message += "'snr_sum', 'snr_max'] instead."
				# --------------------------------------------------------------------------
				err.error(message, fatal=True, frame=True)



# ---------------------
# ---- IMPORT DATA ----
# ---------------------

err.print_progress_message("Loading data cube(s)", t0)
kwargs = Parameters["import"].copy()
kwargs.update({"doFlag": Parameters["steps"]["doFlag"], "flagRegions": Parameters["flag"]["regions"], "flagFile": Parameters["flag"]["file"]})
np_Cube, dict_Header, mask, subcube = import_data.read_data(Parameters["steps"]["doSubcube"], **kwargs)
#np_Cube, dict_Header, mask, subcube = import_data_2.import_data(Parameters["steps"]["doSubcube"], **kwargs)
err.message("Data cube(s) loaded.")
if Parameters["pipeline"]["trackMemory"]: print_memory_usage(t0)


# -------------------------
# ---- PRECONDITIONING ----
# -------------------------

if Parameters["steps"]["doSmooth"] or Parameters["steps"]["doScaleNoise"] or Parameters["steps"]["doWavelet"]:
	err.print_progress_message("Applying input filters", t0)
	if Parameters["pipeline"]["trackMemory"]: print_memory_usage(t0)

# ---- SMOOTHING ----
if Parameters["steps"]["doSmooth"]:
示例#4
0
        + outroot
    )
else:
    if outputDir[-1] != "/":
        outputDir += "/"
    outroot = outputDir + outroot


# ---------------------
# ---- IMPORT DATA ----
# ---------------------

print "\n--- SoFiA: Reading data cube(s) ---"
sys.stdout.flush()

np_Cube, dict_Header, mask = import_data.read_data(**Parameters["import"])


# -------------------------
# ---- PRECONDITIONING ----
# -------------------------

print "\n--- SoFiA: Running input filters ---"
sys.stdout.flush()

# ---- FLAGGING ----
if Parameters["steps"]["doFlag"]:
    np_Cube = flag_cube.flag(np_Cube, **Parameters["flag"])

# ---- SMOOTHING ----
if Parameters["steps"]["doSmooth"]: