3

我完全是 SciRuby 的菜鸟。我第一次使用 SciRuby。我正在关注此视频以大致了解如何使用 SciRuby 并绘制图形、图表等。当我转到 localhost:8888 并从右侧下拉菜单中创建新笔记本时(Ruby 2.2.3)

我在 home(~) 目录

笔记本

然后一开始它说内核正在连接,然后死内核消息一次又一次地弹出(在几秒钟的间隙内)。什么都没有发生,我正在写的命令似乎没有效果。请解决这个问题非常感谢。

核心

$ iruby notebook
Could not load bundler: Could not locate Gemfile or .bundle/ directory
[TerminalIPythonApp] WARNING | Subcommand `ipython notebook` is deprecated and will be removed in future versions.
[TerminalIPythonApp] WARNING | You likely want to use `jupyter notebook`... continue in 5 sec. Press Ctrl-C to quit now.
[I 01:13:51.976 NotebookApp] Serving notebooks from local directory: /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin
[I 01:13:51.976 NotebookApp] 0 active kernels 
[I 01:13:51.976 NotebookApp] The Jupyter Notebook is running at: http://localhost:8888/
[I 01:13:51.977 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
Gtk-Message: Failed to load module "pantheon-filechooser-module"

(firefox:8219): Gtk-WARNING **: Unable to locate theme engine in module_path: "pixmap",

(firefox:8219): Gtk-WARNING **: Unable to locate theme engine in module_path: "pixmap",

(firefox:8219): Gtk-WARNING **: Unable to locate theme engine in module_path: "pixmap",

(firefox:8219): Gtk-WARNING **: Unable to locate theme engine in module_path: "pixmap",

(firefox:8219): Gtk-WARNING **: Unable to locate theme engine in module_path: "pixmap",
Gtk-Message: Failed to load module "canberra-gtk-module"
[I 01:14:32.931 NotebookApp] 302 GET / (127.0.0.1) 0.69ms
[I 01:14:39.766 NotebookApp] Creating new file in 
[I 01:14:53.999 NotebookApp] Creating new notebook in 
[I 01:14:56.223 NotebookApp] Kernel started: 463b14e0-9f3d-49c0-bd3d-6dd19e7b43d9
W, [2016-03-13T01:14:56.726775 #8272]  WARN -- : Could not load bundler: Could not locate Gemfile or .bundle/ directory

/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:163:in `rescue in root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:159:in `root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:71:in `bundle_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:401:in `configure_gem_home_and_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:57:in `configure'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:118:in `definition'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:109:in `check_bundler'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:67:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
You should install rbczmq or ffi_rzmq before running iruby notebook. See README.
F, [2016-03-13T01:14:56.821066 #8272] FATAL -- : Kernel died: uninitialized constant IRuby::Kernel::Session
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize': uninitialized constant IRuby::Kernel::Session (NameError)
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
[I 01:14:59.223 NotebookApp] KernelRestarter: restarting kernel (1/5)
W, [2016-03-13T01:14:59.619447 #8309]  WARN -- : Could not load bundler: Could not locate Gemfile or .bundle/ directory
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:163:in `rescue in root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:159:in `root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:71:in `bundle_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:401:in `configure_gem_home_and_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:57:in `configure'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:118:in `definition'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:109:in `check_bundler'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:67:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
You should install rbczmq or ffi_rzmq before running iruby notebook. See README.
F, [2016-03-13T01:14:59.696087 #8309] FATAL -- : Kernel died: uninitialized constant IRuby::Kernel::Session
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize': uninitialized constant IRuby::Kernel::Session (NameError)
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
[I 01:15:02.231 NotebookApp] KernelRestarter: restarting kernel (2/5)
W, [2016-03-13T01:15:02.619460 #8312]  WARN -- : Could not load bundler: Could not locate Gemfile or .bundle/ directory
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:163:in `rescue in root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:159:in `root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:71:in `bundle_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:401:in `configure_gem_home_and_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:57:in `configure'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:118:in `definition'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:109:in `check_bundler'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:67:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
You should install rbczmq or ffi_rzmq before running iruby notebook. See README.
F, [2016-03-13T01:15:02.703792 #8312] FATAL -- : Kernel died: uninitialized constant IRuby::Kernel::Session
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize': uninitialized constant IRuby::Kernel::Session (NameError)
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
[I 01:15:05.239 NotebookApp] KernelRestarter: restarting kernel (3/5)
W, [2016-03-13T01:15:05.714227 #8316]  WARN -- : Could not load bundler: Could not locate Gemfile or .bundle/ directory
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:163:in `rescue in root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:159:in `root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:71:in `bundle_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:401:in `configure_gem_home_and_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:57:in `configure'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:118:in `definition'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:109:in `check_bundler'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:67:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
You should install rbczmq or ffi_rzmq before running iruby notebook. See README.
F, [2016-03-13T01:15:05.788401 #8316] FATAL -- : Kernel died: uninitialized constant IRuby::Kernel::Session
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize': uninitialized constant IRuby::Kernel::Session (NameError)
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
[W 01:15:06.731 NotebookApp] Timeout waiting for kernel_info reply from 463b14e0-9f3d-49c0-bd3d-6dd19e7b43d9
[I 01:15:08.247 NotebookApp] KernelRestarter: restarting kernel (4/5)
WARNING:root:kernel 463b14e0-9f3d-49c0-bd3d-6dd19e7b43d9 restarted
W, [2016-03-13T01:15:08.701757 #8318]  WARN -- : Could not load bundler: Could not locate Gemfile or .bundle/ directory
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:163:in `rescue in root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:159:in `root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:71:in `bundle_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:401:in `configure_gem_home_and_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:57:in `configure'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:118:in `definition'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:109:in `check_bundler'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:67:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
You should install rbczmq or ffi_rzmq before running iruby notebook. See README.
F, [2016-03-13T01:15:08.779382 #8318] FATAL -- : Kernel died: uninitialized constant IRuby::Kernel::Session
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize': uninitialized constant IRuby::Kernel::Session (NameError)
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
[W 01:15:11.256 NotebookApp] KernelRestarter: restart failed
[W 01:15:11.257 NotebookApp] Kernel 463b14e0-9f3d-49c0-bd3d-6dd19e7b43d9 died, removing from map.
ERROR:root:kernel 463b14e0-9f3d-49c0-bd3d-6dd19e7b43d9 restarted failed!
[W 01:15:11.329 NotebookApp] Kernel deleted before session
[W 01:15:11.330 NotebookApp] 410 DELETE /api/sessions/2709e672-f333-42d4-a84b-0c3ab68d3864 (127.0.0.1) 2.11ms referer=http://localhost:8888/notebooks/Untitled.ipynb?kernel_name=ruby
ryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:159:in `root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:71:in `bundle_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:401:in `configure_gem_home_and_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:57:in `configure'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:118:in `definition'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:109:in `check_bundler'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:67:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
You should install rbczmq or ffi_rzmq before running iruby notebook. See README.
F, [2016-03-13T01:15:02.703792 #8312] FATAL -- : Kernel died: uninitialized constant IRuby::Kernel::Session
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/kernel.rb:18:in `initialize': uninitialized constant IRuby::Kernel::Session (NameError)
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `new'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:70:in `run_kernel'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/bin/iruby:5:in `<top (required)>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `load'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/iruby:23:in `<main>'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
    from /home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'
[I 01:15:05.239 NotebookApp] KernelRestarter: restarting kernel (3/5)
W, [2016-03-13T01:15:05.714227 #8316]  WARN -- : Could not load bundler: Could not locate Gemfile or .bundle/ directory
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:163:in `rescue in root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:159:in `root'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:71:in `bundle_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:401:in `configure_gem_home_and_path'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:57:in `configure'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/bundler-1.11.2/lib/bundler.rb:118:in `definition'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:109:in `check_bundler'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:67:in `run_kernel'
/home/abhimanyuaryan/.rvm/gems/ruby-2.2.3/gems/iruby-0.2.8/lib/iruby/command.rb:34:in `run'
/home/abhimanyuarya[I 01:15:53.124 NotebookApp] Saving file at /Untitled.ipynb
4

3 回答 3

3

是伊万的回答让我失望了。

除了声明 iruby 和 nyaplot gem 之外,您还需要声明相应的 ZeroMQ 接口。

所以,在你的 Gemfile 中,

gem 'iruby'
gem 'nyaplot'
gem 'rbczmq' # or 'ffi-rzmq'
# any other gems you want to use should go here too

或者,如果您正在使用 gemspec 进行项目,则需要在规范中添加以下两行:

gem.add_development_dependency 'iruby', '~>0.2'
gem.add_development_dependency 'rbczmq'

如果你正在使用它,还有一个用于 nyaplot。

于 2016-03-16T19:08:57.800 回答
2

这种方法对我有帮助:我在SciRuby 的 GitHub
页面 之后在 jupyter notebook 中安装了 ruby​​ 内核,并且当天运行良好。但几天后,我再次运行它,内核开始死机。我不知道这背后的确切原因,但我再次遵循相同的方法,它安装了一些额外的宝石并且它起作用了!! 按照这个


sudo apt install libtool libffi-dev ruby ruby-dev make
sudo apt install libzmq3-dev libczmq-dev
gem install cztop iruby
iruby register --force

再次运行笔记本

jupyter-notebook
于 2018-06-19T07:23:10.697 回答
2

尝试将名为 Gemfile 的文件添加到用于运行 iruby 的文件夹中,其内容如下:

gem 'iruby'
gem 'nyaplot'
# any other gems you want to use should go here too
于 2016-03-15T06:50:18.240 回答