Skip to content

Instantly share code, notes, and snippets.

Avatar

Brian Russo brianrusso

  • Tampa, FL
View GitHub Profile
View 0_beautifulsoup.py
# 10_basic.py
# 15_make_soup.py
# 20_search.py
# 25_navigation.py
# 30_edit.py
# 40_encoding.py
# 50_parse_only_part.py
View index.html
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link rel="stylesheet" href="index.css">
</head>
<div style="width: 972px; margin: 0 auto; text-align: left;">
<div id="main" style="border: 1px solid #999; padding: 0; width: 970px;">
<div id="interactiveShell">
<div class="columnGroup firstColumnGroup">
<div class="ledeStory">
View marginnotes.js
function marginotes(els, options) {
var options = options || {}
var marginTooltips = document.getElementsByClassName('margintooltip')
var marginTooltip
if (marginTooltips.length === 0) {
marginTooltip = document.createElement('div')
marginTooltip.className = 'margintooltip'
marginTooltip.style.display = 'none'
document.body.appendChild(marginTooltip)
} else {
@brianrusso
brianrusso / tensorflow_self_check.py
Created Aug 25, 2017 — forked from mrry/tensorflow_self_check.py
TensorFlow on Windows self-check
View tensorflow_self_check.py
# Copyright 2015 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
View deepdictmerge.py
# If add is True (default, it will add them, else it merges.
def deepdictmerge(a, b, path=None, add=True):
if path is None: path = []
for key in b: # for every key in b..
if key not in a: # handle simple case where it's new
a[key] = b[key]
else: # key must be in a and b
# both dictionaries.
if isinstance(a[key], dict) and isinstance(b[key], dict):
deepdictmerge(a[key], b[key], path + [str(key)]) # recurse down
View 20collab.json
{
"directed" : false,
"graph" : {},
"nodes" : [{
"id" : 1376262
}, {
"id" : 1277961
}, {
"id" : 163853
}, {
View 20collabs_aminer.json
{
"directed" : false,
"graph" : {},
"nodes" : [{
"id" : 1376262
}, {
"id" : 1277961
}, {
"id" : 163853
}, {
View aminer_subgraph1.json
{"directed": false, "graph": {}, "nodes": [{"id": 716800}, {"id": 1017728}, {"id": 22275}, {"id": 592388}, {"id": 120709}, {"id": 498694}, {"id": 25099}, {"id": 1155212}, {"id": 677774}, {"id": 321039}, {"id": 121248}, {"id": 358806}, {"id": 196759}, {"id": 151576}, {"id": 1691674}, {"id": 385563}, {"id": 223901}, {"id": 379550}, {"id": 27717}, {"id": 583200}, {"id": 99708}, {"id": 555043}, {"id": 649253}, {"id": 55720}, {"id": 1152297}, {"id": 479794}, {"id": 1666738}, {"id": 950150}, {"id": 1390265}, {"id": 807866}, {"id": 1484732}, {"id": 580029}, {"id": 119614}, {"id": 470816}, {"id": 1438145}, {"id": 304324}, {"id": 1329477}, {"id": 411336}, {"id": 1603212}, {"id": 1280202}, {"id": 239820}, {"id": 114381}, {"id": 1627345}, {"id": 407843}, {"id": 1181785}, {"id": 516442}, {"id": 305115}, {"id": 36828}, {"id": 1264634}, {"id": 1239936}, {"id": 1051235}, {"id": 1175656}, {"id": 1574249}, {"id": 1266027}, {"id": 468845}, {"id": 1225149}, {"id": 943400}, {"id": 1421824}, {"id": 1690612}, {"id": 1669467}, {"id
View aminer_subgraph1.json
{"directed": false, "graph": {}, "nodes": [{"id": 716800}, {"id": 1017728}, {"id": 22275}, {"id": 592388}, {"id": 120709}, {"id": 498694}, {"id": 25099}, {"id": 1155212}, {"id": 677774}, {"id": 321039}, {"id": 121248}, {"id": 358806}, {"id": 196759}, {"id": 151576}, {"id": 1691674}, {"id": 385563}, {"id": 223901}, {"id": 379550}, {"id": 27717}, {"id": 583200}, {"id": 99708}, {"id": 555043}, {"id": 649253}, {"id": 55720}, {"id": 1152297}, {"id": 479794}, {"id": 1666738}, {"id": 950150}, {"id": 1390265}, {"id": 807866}, {"id": 1484732}, {"id": 580029}, {"id": 119614}, {"id": 470816}, {"id": 1438145}, {"id": 304324}, {"id": 1329477}, {"id": 411336}, {"id": 1603212}, {"id": 1280202}, {"id": 239820}, {"id": 114381}, {"id": 1627345}, {"id": 407843}, {"id": 1181785}, {"id": 516442}, {"id": 305115}, {"id": 36828}, {"id": 1264634}, {"id": 1239936}, {"id": 1051235}, {"id": 1175656}, {"id": 1574249}, {"id": 1266027}, {"id": 468845}, {"id": 1225149}, {"id": 943400}, {"id": 1421824}, {"id": 1690612}, {"id": 1669467}, {"id
View clavinclient.py
import json
import geojson
import requests
class ClavinClient(object):
def __init__(self, clavin_endpoint=None):
if clavin_endpoint is None:
#self.clavin_endpoint = "http://54.186.35.170:9090/api/v0/geotag"