(function() {
  var fn = function() {
    
    (function(root) {
      function now() {
        return new Date();
      }
    
      var force = false;
    
      if (typeof (root._bokeh_onload_callbacks) === "undefined" || force === true) {
        root._bokeh_onload_callbacks = [];
        root._bokeh_is_loading = undefined;
      }
    
      
      
    
      
      
    
      function run_callbacks() {
        try {
          root._bokeh_onload_callbacks.forEach(function(callback) { callback() });
        }
        finally {
          delete root._bokeh_onload_callbacks
        }
        console.info("Bokeh: all callbacks have finished");
      }
    
      function load_libs(js_urls, callback) {
        root._bokeh_onload_callbacks.push(callback);
        if (root._bokeh_is_loading > 0) {
          console.log("Bokeh: BokehJS is being loaded, scheduling callback at", now());
          return null;
        }
        if (js_urls == null || js_urls.length === 0) {
          run_callbacks();
          return null;
        }
        console.log("Bokeh: BokehJS not loaded, scheduling load and callback at", now());
        root._bokeh_is_loading = js_urls.length;
        for (var i = 0; i < js_urls.length; i++) {
          var url = js_urls[i];
          var s = document.createElement('script');
          s.src = url;
          s.async = false;
          s.onreadystatechange = s.onload = function() {
            root._bokeh_is_loading--;
            if (root._bokeh_is_loading === 0) {
              console.log("Bokeh: all BokehJS libraries loaded");
              run_callbacks()
            }
          };
          s.onerror = function() {
            console.warn("failed to load library " + url);
          };
          console.log("Bokeh: injecting script tag for BokehJS library: ", url);
          document.getElementsByTagName("head")[0].appendChild(s);
        }
      };var element = document.getElementById("316518c2-721f-447e-a4c4-52984f17d9ff");
      if (element == null) {
        console.log("Bokeh: ERROR: autoload.js configured with elementid '316518c2-721f-447e-a4c4-52984f17d9ff' but no matching script tag was found. ")
        return false;
      }
    
      var js_urls = ["https://cdn.pydata.org/bokeh/release/bokeh-0.12.9.min.js", "https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.9.min.js", "https://cdn.pydata.org/bokeh/release/bokeh-tables-0.12.9.min.js", "https://cdn.pydata.org/bokeh/release/bokeh-gl-0.12.9.min.js"];
    
      var inline_js = [
        function(Bokeh) {
          Bokeh.set_log_level("info");
        },
        
        function(Bokeh) {
          
        },
        
        function(Bokeh) {
          (function() {
            var fn = function() {
              Bokeh.safely(function() {
                (function(root) {
                  function embed_document(root) {
                    var docs_json = {"255ac985-492a-44a9-8217-ab60764999df":{"roots":{"references":[{"attributes":{},"id":"669d75ac-01a2-4a69-abfe-cc8f2d6ab13a","type":"BasicTickFormatter"},{"attributes":{},"id":"bbd72f6b-d7ba-4046-8863-84d2821eac75","type":"PanTool"},{"attributes":{"active_drag":"auto","active_inspect":"auto","active_scroll":"auto","active_tap":"auto","tools":[{"id":"bbd72f6b-d7ba-4046-8863-84d2821eac75","type":"PanTool"},{"id":"ef74d284-5aa7-4a44-900f-d23ea17b6eaf","type":"WheelZoomTool"},{"id":"4df4773a-eb65-4d4d-9337-29205297f96d","type":"BoxZoomTool"},{"id":"6fa5d4c2-fee8-4d82-b373-c183db792114","type":"SaveTool"},{"id":"4bd8501e-d6b5-4b67-9474-7e8d203f3347","type":"ResetTool"},{"id":"fb31945b-7b5d-4a05-a7b8-8fc8f5389fd6","type":"HelpTool"}]},"id":"155e7b07-0f62-4259-8053-153471368e68","type":"Toolbar"},{"attributes":{"below":[{"id":"42d4653a-433f-4fc4-b7a8-31db3f13857d","type":"LinearAxis"}],"left":[{"id":"955602fc-36ed-4fef-97fe-77ac72317e49","type":"LinearAxis"}],"plot_height":400,"plot_width":400,"renderers":[{"id":"42d4653a-433f-4fc4-b7a8-31db3f13857d","type":"LinearAxis"},{"id":"eb4cdc00-4e0e-4a15-87fa-033475ae8042","type":"Grid"},{"id":"955602fc-36ed-4fef-97fe-77ac72317e49","type":"LinearAxis"},{"id":"00307c88-1450-4662-8498-30d38963f4d7","type":"Grid"},{"id":"4115e31e-0370-4c01-8766-1c0bab5f2a9b","type":"BoxAnnotation"},{"id":"9ee5f374-dc51-4711-9f6a-c62f17887279","type":"GlyphRenderer"}],"title":null,"toolbar":{"id":"155e7b07-0f62-4259-8053-153471368e68","type":"Toolbar"},"toolbar_location":"below","x_range":{"id":"df18097a-a60f-48e7-9d03-bd6ce9c222c4","type":"DataRange1d"},"x_scale":{"id":"62e315c3-7ef7-4b69-bd46-d8cf11eef85f","type":"LinearScale"},"y_range":{"id":"b07a9e9e-32d9-461b-b2b9-48177966a248","type":"DataRange1d"},"y_scale":{"id":"154e228c-0b84-48aa-857f-713db3bb34a4","type":"LinearScale"}},"id":"e9e0f9b0-400a-4114-a794-090ccc6b1811","subtype":"Figure","type":"Plot"},{"attributes":{},"id":"62e315c3-7ef7-4b69-bd46-d8cf11eef85f","type":"LinearScale"},{"attributes":{"formatter":{"id":"c5ce8d2f-4367-4a0e-b24c-848bb84c633f","type":"BasicTickFormatter"},"plot":{"id":"e9e0f9b0-400a-4114-a794-090ccc6b1811","subtype":"Figure","type":"Plot"},"ticker":{"id":"60f541ed-e720-415b-985e-d36ab5123164","type":"BasicTicker"}},"id":"955602fc-36ed-4fef-97fe-77ac72317e49","type":"LinearAxis"},{"attributes":{"source":{"id":"c12a9026-4109-42af-8db8-a2675d62499b","type":"ColumnDataSource"}},"id":"c7697312-8f9e-4068-9527-ca7ff99f8a7e","type":"CDSView"},{"attributes":{"callback":null},"id":"df18097a-a60f-48e7-9d03-bd6ce9c222c4","type":"DataRange1d"},{"attributes":{"overlay":{"id":"4115e31e-0370-4c01-8766-1c0bab5f2a9b","type":"BoxAnnotation"}},"id":"4df4773a-eb65-4d4d-9337-29205297f96d","type":"BoxZoomTool"},{"attributes":{},"id":"60f541ed-e720-415b-985e-d36ab5123164","type":"BasicTicker"},{"attributes":{"dimension":1,"plot":{"id":"e9e0f9b0-400a-4114-a794-090ccc6b1811","subtype":"Figure","type":"Plot"},"ticker":{"id":"60f541ed-e720-415b-985e-d36ab5123164","type":"BasicTicker"}},"id":"00307c88-1450-4662-8498-30d38963f4d7","type":"Grid"},{"attributes":{"callback":null},"id":"b07a9e9e-32d9-461b-b2b9-48177966a248","type":"DataRange1d"},{"attributes":{},"id":"154e228c-0b84-48aa-857f-713db3bb34a4","type":"LinearScale"},{"attributes":{},"id":"6fa5d4c2-fee8-4d82-b373-c183db792114","type":"SaveTool"},{"attributes":{},"id":"ef74d284-5aa7-4a44-900f-d23ea17b6eaf","type":"WheelZoomTool"},{"attributes":{"callback":null,"column_names":["y","x"],"data":{"x":[1,2,3,4,5],"y":[2,5,8,2,7]}},"id":"c12a9026-4109-42af-8db8-a2675d62499b","type":"ColumnDataSource"},{"attributes":{"fill_alpha":{"value":0.1},"fill_color":{"value":"#1f77b4"},"line_alpha":{"value":0.1},"line_color":{"value":"#1f77b4"},"size":{"units":"screen","value":10},"x":{"field":"x"},"y":{"field":"y"}},"id":"46de8685-860c-49a8-b041-a74af8bfdf25","type":"Circle"},{"attributes":{"fill_color":{"value":"#1f77b4"},"line_color":{"value":"#1f77b4"},"size":{"units":"screen","value":10},"x":{"field":"x"},"y":{"field":"y"}},"id":"6475baec-da57-4156-8cb6-fdf7a965c368","type":"Circle"},{"attributes":{"bottom_units":"screen","fill_alpha":{"value":0.5},"fill_color":{"value":"lightgrey"},"left_units":"screen","level":"overlay","line_alpha":{"value":1.0},"line_color":{"value":"black"},"line_dash":[4,4],"line_width":{"value":2},"plot":null,"render_mode":"css","right_units":"screen","top_units":"screen"},"id":"4115e31e-0370-4c01-8766-1c0bab5f2a9b","type":"BoxAnnotation"},{"attributes":{},"id":"4bd8501e-d6b5-4b67-9474-7e8d203f3347","type":"ResetTool"},{"attributes":{"plot":{"id":"e9e0f9b0-400a-4114-a794-090ccc6b1811","subtype":"Figure","type":"Plot"},"ticker":{"id":"a47f1b6b-e560-443d-b7db-0cda9a940178","type":"BasicTicker"}},"id":"eb4cdc00-4e0e-4a15-87fa-033475ae8042","type":"Grid"},{"attributes":{},"id":"c5ce8d2f-4367-4a0e-b24c-848bb84c633f","type":"BasicTickFormatter"},{"attributes":{},"id":"fb31945b-7b5d-4a05-a7b8-8fc8f5389fd6","type":"HelpTool"},{"attributes":{},"id":"a47f1b6b-e560-443d-b7db-0cda9a940178","type":"BasicTicker"},{"attributes":{"data_source":{"id":"c12a9026-4109-42af-8db8-a2675d62499b","type":"ColumnDataSource"},"glyph":{"id":"6475baec-da57-4156-8cb6-fdf7a965c368","type":"Circle"},"hover_glyph":null,"muted_glyph":null,"nonselection_glyph":{"id":"46de8685-860c-49a8-b041-a74af8bfdf25","type":"Circle"},"selection_glyph":null,"view":{"id":"c7697312-8f9e-4068-9527-ca7ff99f8a7e","type":"CDSView"}},"id":"9ee5f374-dc51-4711-9f6a-c62f17887279","type":"GlyphRenderer"},{"attributes":{"formatter":{"id":"669d75ac-01a2-4a69-abfe-cc8f2d6ab13a","type":"BasicTickFormatter"},"plot":{"id":"e9e0f9b0-400a-4114-a794-090ccc6b1811","subtype":"Figure","type":"Plot"},"ticker":{"id":"a47f1b6b-e560-443d-b7db-0cda9a940178","type":"BasicTicker"}},"id":"42d4653a-433f-4fc4-b7a8-31db3f13857d","type":"LinearAxis"}],"root_ids":["e9e0f9b0-400a-4114-a794-090ccc6b1811"]},"title":"Bokeh Application","version":"0.12.9"}};
                    var render_items = [{"docid":"255ac985-492a-44a9-8217-ab60764999df","elementid":"316518c2-721f-447e-a4c4-52984f17d9ff","modelid":"e9e0f9b0-400a-4114-a794-090ccc6b1811"}];
                
                    root.Bokeh.embed.embed_items(docs_json, render_items);
                  }
                
                  if (root.Bokeh !== undefined) {
                    embed_document(root);
                  } else {
                    var attempts = 0;
                    var timer = setInterval(function(root) {
                      if (root.Bokeh !== undefined) {
                        embed_document(root);
                        clearInterval(timer);
                      }
                      attempts++;
                      if (attempts > 100) {
                        console.log("Bokeh: ERROR: Unable to embed document because BokehJS library is missing")
                        clearInterval(timer);
                      }
                    }, 10, root)
                  }
                })(window);
              });
            };
            if (document.readyState != "loading") fn();
            else document.addEventListener("DOMContentLoaded", fn);
          })();
        },
        function(Bokeh) {
          console.log("Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-0.12.9.min.css");
          Bokeh.embed.inject_css("https://cdn.pydata.org/bokeh/release/bokeh-0.12.9.min.css");
          console.log("Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.9.min.css");
          Bokeh.embed.inject_css("https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.9.min.css");
          console.log("Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-tables-0.12.9.min.css");
          Bokeh.embed.inject_css("https://cdn.pydata.org/bokeh/release/bokeh-tables-0.12.9.min.css");
        }
      ];
    
      function run_inline_js() {
        
        for (var i = 0; i < inline_js.length; i++) {
          inline_js[i].call(root, root.Bokeh);
        }
        
      }
    
      if (root._bokeh_is_loading === 0) {
        console.log("Bokeh: BokehJS loaded, going straight to plotting");
        run_inline_js();
      } else {
        load_libs(js_urls, function() {
          console.log("Bokeh: BokehJS plotting callback run at", now());
          run_inline_js();
        });
      }
    }(window));
  };
  if (document.readyState != "loading") fn();
  else document.addEventListener("DOMContentLoaded", fn);
})();
