示例#1
0
          hover_line_color='red')

pw.circle('x1',
          'y1',
          source=source_comp,
          radius=0.015,
          fill_color='lightgray',
          line_color='black',
          line_width=0.3)

taptool = pw.select(type=TapTool)
taptool.callback = OpenURL(url=url)

# bokeh.pydata.org/en/latest/docs/reference/models/annotations.html
wcolor_bar = ColorBar(color_mapper=wmapper,
                      label_standoff=-13,
                      major_label_text_font_style="bold",
                      padding=26,
                      major_label_text_align='right',
                      major_label_text_font_size="10pt",
                      location=(0, 0))

pw.add_layout(wcolor_bar, 'left')

info_col = Div(text=write_description('xwsigma'), width=2 * pw.plot_width)
layoutplot = row([px, pw], responsive=False)  #, sizing_mode='scale_width')
layout = column(widgetbox(info_col), layoutplot)

curdoc().add_root(layout)
curdoc().title = "XWSIGMA"
示例#2
0
         hover_line_color='red')

taptool = p.select(type=TapTool)
taptool.callback = OpenURL(url=url)

## px.circle('x1','y1', source = source_comp, radius = 0.015,
##         fill_color = 'lightgray', line_color='black', line_width=0.3)

# bokeh.pydata.org/en/latest/docs/reference/models/annotations.html
xcolor_bar = ColorBar(color_mapper=mapper,
                      label_standoff=-13,
                      major_label_text_font_style="bold",
                      padding=26,
                      major_label_text_align='right',
                      major_label_text_font_size="10pt",
                      location=(0, 0))

p.add_layout(xcolor_bar, 'left')

#infos
info, nlines = write_info('skypeak', tests['skypeak'])
txt = PreText(text=info, height=nlines * 20, width=p.plot_width)
info_col = Div(text=write_description('skypeak'), width=p.plot_width)
p2txt = column(widgetbox(info_col), p)

layout = gridplot([[p2txt]])

# End of Bokeh Block
curdoc().add_root(layout)
curdoc().title = "SKYPEAK"
示例#3
0
</table>
</div>

"""
txt_keys = [
    'CUTLO', 'CUTMED', 'CUTHI', 'NGOODFIB_NORMAL_RANGE', 'NGOODFIB_WARN_RANGE'
]
for i in range(5):
    html_str = html_str.replace('%s%s' % ("param", str(i)),
                                str(tests['countbins'][txt_keys[i]]))

div = Div(text=html_str, width=400, height=200)
# ---------

# plow.legend.location = "top_left"
# layout = gridplot( [phi,pmed,plow,None], ncols=2, plot_width=600, plot_height=600)

layout_plot = gridplot([plow, pmed, phi, div],
                       ncols=2,
                       responsive=False,
                       plot_width=600,
                       plot_height=600)
info_col = Div(text=write_description('countbins'), width=1200)
layout = column(widgetbox(info_col), layout_plot)

# End of Bokeh Block
curdoc().add_root(layout)

curdoc().title = "COUNTBINS"
示例#4
0
color_bar = ColorBar(color_mapper=mapper,
                     major_label_text_align='left',
                     major_label_text_font_size='10pt',
                     label_standoff=2,
                     location=(0, 0),
                     formatter=formatter,
                     title="(ADU)",
                     title_text_baseline="alphabetic")

p.add_layout(color_bar, 'right')

p.xaxis.major_label_text_font_size = '0pt'  # turn off x-axis tick labels
p.yaxis.major_label_text_font_size = '0pt'  # turn off y-axis tick labels
p.xaxis.major_tick_line_color = None  # turn off x-axis major ticks
p.xaxis.minor_tick_line_color = None  # turn off x-axis minor ticks

p.yaxis.major_tick_line_color = None  # turn off y-axis major ticks
p.yaxis.minor_tick_line_color = None  # turn off y-axis minor ticks

#infos
info, nlines = write_info('getbias', tests['getbias'])
txt = PreText(text=info, height=nlines * 20, width=p.plot_width)
info_col = Div(text=write_description('getbias'), width=p.plot_width)
ptxt = column(widgetbox(info_col), p)

#output_notebook()

# End of Bokeh Block
curdoc().add_root(ptxt)
curdoc().title = "GETBIAS"
示例#5
0
# marking the Hover point
p2.circle('ra',
          'dec',
          source=source2,
          radius=0.0186,
          fill_color=None,
          line_color=None,
          hover_fill_color={
              'field': 'integ',
              'transform': mapper
          },
          line_width=3,
          hover_line_color='red')

color_bar.formatter = formatter
p2.add_layout(color_bar, 'left')

#infos
info, nlines = write_info('integ', tests['integ'])
txt = PreText(text=info, height=nlines * 20, width=p2.plot_width)
p2txt = column(widgetbox(txt), p2)

#layout = gridplot([[p2txt]], responsive=False)
info_col = Div(text=write_description('integ'), width=p2.plot_width)
layout = column(info_col, p2)

# End of Bokeh Block
curdoc().add_root(layout)
curdoc().title = "INTEG"
示例#6
0
文件: main.py 项目: mluizasanchez/qlf
p.text(x="x", y="y_offset1", text="amp", text_font_size="18pt", **text_props)
formatter = PrintfTickFormatter(format='%2.1e')
color_bar = ColorBar(color_mapper=mapper,
                     major_label_text_align='left',
                     major_label_text_font_size='10pt',
                     label_standoff=2,
                     location=(0, 0),
                     formatter=formatter,
                     title="(ADU)",
                     title_text_baseline="alphabetic")

p.add_layout(color_bar, 'right')

p.xaxis.major_label_text_font_size = '0pt'  # turn off x-axis tick labels
p.yaxis.major_label_text_font_size = '0pt'  # turn off y-axis tick labels
p.xaxis.major_tick_line_color = None  # turn off x-axis major ticks
p.xaxis.minor_tick_line_color = None  # turn off x-axis minor ticks

p.yaxis.major_tick_line_color = None  # turn off y-axis major ticks
p.yaxis.minor_tick_line_color = None  # turn off y-axis minor ticks

#infos
info, nlines = write_info('countpix', tests['countpix'])
txt = PreText(text=info, height=nlines * 20, width=p.plot_width)
info_col = Div(text=write_description('countpix'), width=2 * p.plot_width)
ptxt = column(widgetbox(info_col), p)

# End of Bokeh Block
curdoc().add_root(ptxt)
curdoc().title = "COUNTPIX"
示例#7
0
          fill_color=None,
          line_color=None,
          line_width=3,
          hover_line_color='red',
          hover_fill_color='lightgrey')

taptool = p2.select(type=TapTool)
taptool.callback = OpenURL(url=url)

color_bar = ColorBar(color_mapper=mapper,
                     label_standoff=-13,
                     major_label_text_font_style='bold',
                     padding=26,
                     major_label_text_align='right',
                     major_label_text_font_size="10pt",
                     location=(0, 0))

p2.add_layout(color_bar, 'left')

#infos
info, nlines = write_info('skycont', tests['skycont'])
txt = PreText(text=info, height=nlines * 20, width=p2.plot_width)
info_col = Div(text=write_description('skycont'), width=p2.plot_width)
p2txt = column(widgetbox(info_col), p2)

layout = gridplot([[p2txt]], responsive=False)

# End of Bokeh Block
curdoc().add_root(layout)
curdoc().title = "SKYCONT"