Skip to content

Instantly share code, notes, and snippets.

View brynpickering's full-sized avatar

Bryn Pickering brynpickering

View GitHub Profile
@brynpickering
brynpickering / test.log
Last active November 5, 2019 15:12
archetypal test log
============================= test session starts ==============================
platform darwin -- Python 3.7.5, pytest-5.2.2, py-1.8.0, pluggy-0.13.0
rootdir: brynpickering_archetypal_dir
collected 221 items
tests/test_cli.py
Table ZoneVentilation Airflow Stats Nominal does not exist. Returning an empty DataFrame
object "SCHEDULE:CONSTANT" already exists in idf file
object "SCHEDULE:CONSTANT" already exists in idf file
Completed 'VentilationSetting.from_zone' for 'Core_VentilationSetting' in 0.054 s
@brynpickering
brynpickering / jupyter_job.sh
Last active April 23, 2020 09:55
Load Jupyter lab on a ETH euler compute node
#!/bin/bash
#BSUB -J jupyter_lab[8889]
#BSUB -n 1
#BSUB -W 480
#BSUB -R "rusage[mem=80G]"
#BSUB -o jupyter-%I.log
# get tunnelling info
XDG_RUNTIME_DIR=""
node=$(hostname -s)
@brynpickering
brynpickering / requirements.yaml
Created June 6, 2018 07:03
Visualisastion tutorial - openmod workshop Zurich 2018
name: vis-tutorial
channels:
- conda-forge
- defaults
dependencies:
- matplotlib=2.1.0
- notebook=5.1.0
- numpy=1.14.1
- pandas=0.22
- plotly=2.5
@brynpickering
brynpickering / build_network_with_hover.py
Created October 12, 2017 15:39
Plotly network implementation
# direct copy from https://stackoverflow.com/questions/46037897/line-hover-text-in-plotly with some lines changed (originals in comments)
import plotly.offline as py
from plotly.graph_objs import *
py.init_notebook_mode(connected=True)
import networkx as nx
G=nx.random_geometric_graph(200,0.125)
pos=nx.get_node_attributes(G,'pos')