Restores a previously hidden edge back into the graph.
322357
def restore_edge(self, edge):
        
        try:
            head_id, tail_id, data = self.hidden_edges[edge]
            self.nodes[tail_id][0].append(edge)
            self.nodes[head_id][1].append(edge)
            self.edges[edge] = head_id, tail_id, data
            del self.hidden_edges[edge]
        except KeyError:
            raise GraphError('Invalid edge %s' % edge)
1142877
function restore() {
    if (isPrevented) {
        const { body } = document;
        if (previousStyles) {
            body.setAttribute('style', previousStyles);
        } else {
            body.removeAttribute('style');
        }

        window.scrollTo(...previousPosition);
        resizeUtil.removeEventListener('', recalculate);
        isPrevented = false;
    }
}
747480
function restore() {
    var data = store.get() || {};
    addEvent('load', function () {
      //console.log('scrolling to', data.y);
      window.scrollTo(data.x, data.y);
    });
  }
704703
def remove_edge(self, u, v):
        
        # Remove (u, v) from represented graph
        print('Dynamically removing uv=(%r, %r)' % (u, v))
        self.graph.remove_edge(u, v)
        e = (u, v)
        # Remove edge e = (u, v) from all graphs.
        if not self.forests[0].has_edge(u, v):
            # If (u, v) is a non-tree edge, simply delete it.
            # Nothing else to do.
            return
        # If (u, v) is a tree edge we delete it and search for a replacement.
        # Delete from all higher levels
        for i in reversed(range(0, self.level[e] + 1)):
            self.forests[i].remove_edge(u, v)

        # Determine if another edge that connects u and v exists.
        # (This must be an edge r, level[r] <= level[e])
        # (Find max possible level[r] <= level[e])
        for i in reversed(range(0, self.level[e] + 1)):
            # Tu != Tw b/c (u, v) was just deleted from all forests
            Tu = self.forests[i].subtree(u)
            print('Tu = %r' % (list(Tu.nodes()),))
            Tv = self.forests[i].subtree(v)
            print('Tv = %r' % (list(Tv.nodes()),))
            # Relabel so len(Tu) <= len(Tv)
            # This ensures len(Tu) < 2 ** (floor(log(n)) - i)
            if len(Tu) > len(Tv):
                Tu, Tv = Tv, Tu
                # Note len(Tu) <= 2 * (len(Tu) + len(Tv) + 1)
            # We can afford to push all of Tu's edges to the next level and
            # still preserve invariant 1.
            seen_ = set([])
            for x in Tu.nodes():
                # Visit all edges INCIDENT (in real graph) to nodes in Tu.
                # This lets us find non-tree edges to make a tree edge
                seen_.add(x)
                for y in self.graph.neighbors(x):
                    if y in seen_:
                        continue
                    # print('Check replacement edge xy=(%r, %r)' % (x, y))
                    if y in Tv:
                        print('* Found replacement xy=(%r, %r)' % (x, y))
                        # edge (x, y) is a replacement edge.
                        # add (x, y) to prev forests F[0:i+1]
                        # This is the only place edges are added to forets of
                        # higher levels.
                        if len(self.forests) == i + 1:
                            self.forests.append(DummyEulerTourForest(self.graph.nodes()))
                        for j in range(0, i + 2):
                            print('* Add replacment to F[j=%r]' % (j,))
                            # Need euler tree augmentation for outgoing level edges
                            self.forests[j].add_edge(x, y)
                        return
                    else:
                        print('* Charging xy=(%r, %r)' % (x, y))
                        # charge --- add (x, y) to next level
                        # this pays for our search in an amortized sense
                        # (ie, the next search at this level wont consider this)
                        if len(self.forests) == i + 1:
                            self.forests.append(DummyEulerTourForest(self.graph.nodes()))
                        if self.forests[i].has_edge(x, y):
                            self.forests[i + 1].add_edge(x, y)
                        #     # assert False, 'we got it, should add it?'
                        self.level[(x, y)] = i + 1
259705
def reconstruct(self, D=None):
        """"""

        if D is None:
            Df = self.Xf
        else:
            Df = sl.rfftn(D, None, self.cri.axisN)

        Sf = np.sum(self.Zf * Df, axis=self.cri.axisM)
        return sl.irfftn(Sf, self.cri.Nv, self.cri.axisN)
1210243
function redraw() {

			// hide tooltip and hover states
			if (tracker.resetTracker) {
				tracker.resetTracker();
			}

			// render the axis
			render();

			// move plot lines and bands
			each(plotLinesAndBands, function (plotLine) {
				plotLine.render();
			});

			// mark associated series as dirty and ready for redraw
			each(associatedSeries, function (series) {
				series.isDirty = true;
			});

		}
724420
public void reset()
   {
      unusedEdges.addAll(usedEdges);
      unusedNodes.addAll(usedNodes);

      usedEdges.clear();
      usedNodes.clear();
   }
366614
def reconstruct(self, D=None, X=None):
        """"""

        if D is None:
            D = self.getdict(crop=False)
        if X is None:
            X = self.getcoef()
        Df = sl.rfftn(D, self.xstep.cri.Nv, self.xstep.cri.axisN)
        Xf = sl.rfftn(X, self.xstep.cri.Nv, self.xstep.cri.axisN)
        DXf = sl.inner(Df, Xf, axis=self.xstep.cri.axisM)
        return sl.irfftn(DXf, self.xstep.cri.Nv, self.xstep.cri.axisN)
1330734
def _make_return_edges(self):
        

        for func_addr, func in self.functions.items():
            if func.returning is False:
                continue

            # get the node on CFG
            if func.startpoint is None:
                l.warning('Function %#x does not have a startpoint (yet).', func_addr)
                continue

            startpoint = self.model.get_any_node(func.startpoint.addr)
            if startpoint is None:
                # weird...
                l.warning('No CFGNode is found for function %#x in _make_return_edges().', func_addr)
                continue

            endpoints = self._get_return_sources(func)

            # get all callers
            callers = self.model.get_predecessors(startpoint, jumpkind='Ijk_Call')
            # for each caller, since they all end with a call instruction, get the immediate successor
            return_targets = itertools.chain.from_iterable(
                self.model.get_successors(caller, excluding_fakeret=False, jumpkind='Ijk_FakeRet') for caller in callers
            )
            return_targets = set(return_targets)

            for ep in endpoints:
                src = self.model.get_any_node(ep.addr)
                for rt in return_targets:
                    if not src.instruction_addrs:
                        ins_addr = None
                    else:
                        if self.project.arch.branch_delay_slot:
                            if len(src.instruction_addrs) > 1:
                                ins_addr = src.instruction_addrs[-2]
                            else:
                                l.error('At %s: expecting more than one instruction. Only got one.', src)
                                ins_addr = None
                        else:
                            ins_addr = src.instruction_addrs[-1]

                    self._graph_add_edge(rt, src, 'Ijk_Ret', ins_addr, DEFAULT_STATEMENT)
1337931
def reconstruct(self, X=None):
        """"""

        if X is None:
            X = self.X
        return self.D.dot(self.X)
823401
private void reinitializeIfNecessary() {
        if (this.resourceCache == null || this.resourceCache.size() > 0) {
            this.resourcesGraph = new ListenableDirectedGraph<>(DefaultEdge.class);
            this.neighborIndex = new DirectedNeighborIndex<>(this.resourcesGraph);
            this.resourcesGraph.addGraphListener(neighborIndex);
            this.resourceCache = new HashMap<>();
            this.resourcesGraph.addVertexSetListener(new VertexCacheListener());
        }
    }
1315246
def reroot_graph(G: nx.DiGraph, node: str) -> nx.DiGraph:
    """"""
    G = G.copy()
    for n, successors in list(nx.bfs_successors(G, source=node)):
        for s in successors:
            G.add_edge(s, n, **G.edges[n, s])
            G.remove_edge(n, s)
    return G
820326
def restore(self):
        """"""
        signal.signal(signal.SIGINT, self.original_sigint)
        signal.signal(signal.SIGTERM, self.original_sigterm)
        if os.name == 'nt':
            signal.signal(signal.SIGBREAK, self.original_sigbreak)
50855
public void restore() {
		if (window instanceof RootPaneContainer) {
			final Component glassPane = ((RootPaneContainer) window).getGlassPane();
			glassPane.setVisible(windowGlassPaneVisible);
			glassPane.setCursor(oldWindowCursor);
		}
		if (window != null) {
			window.setCursor(oldWindowCursor);
		}
	}
971681
def unshift_edge(edge)
	    @vertices.unshift(edge.last) unless edge.last == @edges.first.first
	    @vertices.unshift(edge.first) # unless edge.first == @edges.last.last
	    @vertices.pop if @vertices.last == @vertices.first
	    @edges.unshift(edge)
	end
84641
def _remove_hidden_parts(projected_surface):
    
    surface = np.copy(projected_surface)
    surface[~_make_occlusion_mask(projected_surface)] = np.nan
    return surface
961450
def remove_edge(edge)
      delete_edge(edge)
      edge.each_vertex { |vertex| callback(vertex, :edge_removed, edge) }
    end