shutil.copyfile(op.basename(colfile), op.join(outdir_cols, op.basename(colfile))) except: pass outdir_plots = op.join(basedir, outdir, 'plots') if not op.isdir(outdir_plots): os.makedirs(outdir_plots) try: plot_component = 'ne' if fullday[-4:] in plot_component_dict: plot_component = plot_component_dict[fullday[-4:]] plotfn = smplplt.plotedi(outfn, saveplot=True, component=plot_component) shutil.copyfile(op.basename(plotfn), op.join(outdir_plots, op.basename(plotfn))) print 'copied res/phase plot %s' % (plotfn) except: print 'Warning - no res/phase plot for %s' % (fullday) try: plotfncoh = smplpltCOH.plotcoh(outfn_coh, saveplot=True) shutil.copyfile(op.basename(plotfncoh), op.join(outdir_plots, op.basename(plotfncoh))) print 'copied coherence plot %s' % (plotfncoh) except: print 'Warning - no coherence plot for %s' % (fullday)
try: shutil.copyfile(op.basename(colfile), op.join(outdir_cols, op.basename(colfile))) except: pass outdir_plots = op.join(basedir, outdir, "plots") if not op.isdir(outdir_plots): os.makedirs(outdir_plots) try: plot_component = "ne" if fullday[-4:] in plot_component_dict: plot_component = plot_component_dict[fullday[-4:]] plotfn = smplplt.plotedi(outfn, saveplot=True, component=plot_component) shutil.copyfile(op.basename(plotfn), op.join(outdir_plots, op.basename(plotfn))) print "copied res/phase plot %s" % (plotfn) except: print "Warning - no res/phase plot for %s" % (fullday) try: plotfncoh = smplpltCOH.plotcoh(outfn_coh, saveplot=True) shutil.copyfile(op.basename(plotfncoh), op.join(outdir_plots, op.basename(plotfncoh))) print "copied coherence plot %s" % (plotfncoh) except: print "Warning - no coherence plot for %s" % (fullday) pass donefiles = os.listdir(".")