question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

interact() fails with "output_notebook is not defined"

See original GitHub issue

interact() fails with NameError: name ‘output_notebook’ is not defined

This is a fresh installation of jupyter, lightkurve, and bokeh via pip using python 3.6 today.

Explicitly specifying from bokeh.plotting import * (or import outpute_notebook) does not resolve the issue.

`import lightkurve

from lightkurve import KeplerTargetPixelFile

tpf = KeplerTargetPixelFile(“ktwo246199087-c19_lpd-targ.fits”)

tpf.interact()


NameError Traceback (most recent call last) <ipython-input-9-7bfcb21a8385> in <module> ----> 1 tpf.interact()

~/.local/lib/python3.6/site-packages/lightkurve/targetpixelfile.py in interact(self, notebook_url, max_cadences, aperture_mask, exported_filename) 643 max_cadences=max_cadences, 644 aperture_mask=aperture_mask, –> 645 exported_filename=exported_filename) 646 647 def interact_sky(self, notebook_url=‘localhost:8888’, magnitude_limit=18):

~/.local/lib/python3.6/site-packages/lightkurve/interact.py in show_interact_widget(tpf, notebook_url, max_cadences, aperture_mask, exported_filename) 550 doc.add_root(widgets_and_figures) 551 –> 552 output_notebook(verbose=False, hide_banner=True) 553 return show(create_interact_ui, notebook_url=notebook_url) 554

NameError: name ‘output_notebook’ is not defined

`

Environment:

Linux, RHEL 7

  • lightkurve version 1.0b29
  • installation method pip

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:1
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
barentsencommented, Feb 20, 2019

@gully Would you be willing to investigate?

1reaction
gullycommented, Feb 27, 2019

Will do! I suspect the answer is in our optional handling of bokeh dependencies.

Read more comments on GitHub >

github_iconTop Results From Across the Web

interact() fails with "output_notebook is not defined" · Issue #454
This is a fresh installation of jupyter, lightkurve, and bokeh via pip using python 3.6 today. Explicitly specifying from bokeh.plotting import ...
Read more >
output_notebook() is not defined - why? - Stack Overflow
Typical notebooks have following imports: from bokeh.io import output_notebook, show from bokeh.plotting import figure output_notebook().
Read more >
Using with Jupyter — Bokeh 2.4.3 Documentation
Rendered cell output of the output_notebook call ensures that the BokehJS library loads. Otherwise, Bokeh plots will not work. If this cell's type...
Read more >
Display Troubleshooting — Altair 4.2.0 documentation
If you are expecting a chart output and see nothing at all, it means that the Javascript rendering libraries are not being invoked....
Read more >
Dagstermill - Dagster Docs
Dagstermill¶. This library provides an integration with papermill to allow you to run Jupyter notebooks with Dagster. Related Guides:.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found