This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
html | |
----- | |
/var/build/user_builds/py6s/checkouts/stable/doc/source/helpers.rst:59: WARNING: autodoc: failed to import class u'Wavelengths' from module u'Py6S.SixSHelpers'; the following exception was raised: | |
Traceback (most recent call last): | |
File "/home/docs/checkouts/readthedocs.org/user_builds/py6s/envs/stable/local/lib/python2.7/site-packages/sphinx/ext/autodoc.py", line 335, in import_object | |
__import__(self.modname) | |
ImportError: No module named Py6S.SixSHelpers | |
/var/build/user_builds/py6s/checkouts/stable/doc/source/helpers.rst:77: WARNING: autodoc: failed to import class u'Angles' from module u'Py6S.SixSHelpers'; the following exception was raised: | |
Traceback (most recent call last): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE `data` ( | |
`id` int(11) unsigned NOT NULL AUTO_INCREMENT, | |
`timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, | |
`set_point` float DEFAULT NULL, | |
`temp` float DEFAULT NULL, | |
`on` tinyint(1) DEFAULT NULL, | |
PRIMARY KEY (`id`) | |
); | |
INSERT INTO `data` (`id`, `timestamp`, `set_point`, `temp`, `on`) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def duplicate_slide(pres, index): | |
source = pres.slides[index] | |
try: | |
blank_slide_layout = pres.slide_layouts[6] | |
except: | |
blank_slide_layout = pres.slide_layouts[len(pres.slide_layouts) - 1] | |
dest = pres.slides.add_slide(blank_slide_layout) | |
for shp in source.shapes: | |
el = shp.element |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import untangle | |
import serial | |
def get_data(port='/dev/ttyUSB1', verbose=False): | |
"""Gets temperature and power usage data from an attached CurrentCost meter. | |
Parameters: | |
- port: the port that the CurrentCost meter is attached to. Somthing like /dev/ttyUSB0 or COM1 | |
Returns: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:81> | |
WSGIDaemonProcess _graphite processes=5 threads=5 display-name='%{GROUP}' inactivity-timeout=120 user=_graphite group=_graphite | |
WSGIProcessGroup _graphite | |
WSGIImportScript /usr/share/graphite-web/graphite.wsgi process-group=_graphite application-group=%{GLOBAL} | |
WSGIScriptAlias / /usr/share/graphite-web/graphite.wsgi | |
Alias /content/ /usr/share/graphite-web/static/ | |
<Location "/content/"> | |
SetHandler None |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from dateutil.parser import parse | |
import math | |
def get_ozone_conc(lat, lon, timestamp): | |
"""Returns the ozone contents in matm-cm for the given latitude/longitude | |
and timestamp (provided as either a datetime object or a string in any sensible format | |
- I strongly recommend using an ISO 8601 format of yyyy-mm-dd) according to van Heuklon's | |
Ozone model. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright (c) 2013, Robin Wilson | |
# All rights reserved. | |
# | |
# Redistribution and use in source and binary forms, with or without | |
# modification, are permitted provided that the following conditions are met: | |
# * Redistributions of source code must retain the above copyright | |
# notice, this list of conditions and the following disclaimer. | |
# * Redistributions in binary form must reproduce the above copyright | |
# notice, this list of conditions and the following disclaimer in the | |
# documentation and/or other materials provided with the distribution. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
import numpy as np | |
from MonteCarloRegression import MonteCarloRegression | |
mcr = MonteCarloRegression('LAL7_v10_RemoveBrookhaven.csv', 'B1', 'B3') | |
random.seed(123456789) | |
np.random.seed(123456789) | |
mcr.run_from_metadata('/Users/robin/HOTBAR/Test/Inputs/LE71230322001091EDC00_MTL.txt') |