I hereby claim:
- I am rschildmeijer on github.
- I am roger (https://keybase.io/roger) on keybase.
- I have a public key whose fingerprint is E250 ECFE 116B 1105 EED9 EC2D C740 6558 A0B0 EED7
To claim this, I am signing this object:
#ex output: [0.02, 0.019, ..., 0.025] | |
# index = 0, 0.02 = hour 0-1 | |
# index = 1, 0.019 = hour 1-2 | |
# index = 23, 0.025 = hour 23-24 | |
def todays_spot_prices(): | |
return hass.states.get("sensor.nordpool_kwh_se4_sek_3_05_025").as_dict()['attributes']['today'] | |
def get_active_hours(spots): | |
enumerated_hours = sorted(enumerate(spots), key=lambda entry: entry[1])[0:HOURS_TO_RUN] |
<div id="film_wrapper"> | |
<button id="play_btn">Play</button> <div class="large_still"> | |
<img src="https://emilklang.com/wp-content/uploads/vbo4-1200x675.jpg"> | |
</div> | |
<div class="video"><iframe id="player1" src="http://player.vimeo.com/video/299710204?autoplay=0&title=0&portrait=0&byline=0&color=e7e0e0" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe></div> | |
</div> |
MATRIX / MATLAB | |
I = v < 0.05 # I contains 1 or 0 depending on logical criteria | |
v(I) = 0 # element vise assign 0 where I is 1 (True) | |
A .* B # element wise multiplication | |
1 . / v # element wise division (1 / element) | |
v + 1 # element wise | |
a < 3 # element wise comparision | |
log(v), exp(v), abs(v) # element wise | |
sum(a), prod(a), floor(a) |
# formatted (extra line breaks and spaces) for readability | |
45.152: [GC | |
[PSYoungGen: |a|K -> |b|K (|c|K)] | |
|d|K -> |e|K (|f|K), 0.1083183 secs] | |
[Times: user=1.83 sys=0.01, real=0.11 secs] | |
Description: | |
PSYoungGen: Parallell Scavange Young Generation | |
a: Occupancy in young gen before minor gc | |
b: Occupancy in young gen after minor gc. Eden is empty => occupancy in survivor space (ie "survivor space occupancy") |
I hereby claim:
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
/** | |
* A potentially infinite sequence of elements. A stream is a consumable data | |
* structure. The elements of the stream are available for consumption by either | |
* iteration or an operation. Once consumed the elements are no longer available | |
* from the stream. | |
* | |
* @param <T> Type of elements. | |
* | |
* @author Brian Goetz | |
*/ |
curl -silent "https://www.riksgalden.se/sv/omriksgalden/statsskulden/aktuella-siffror/statslanerantan/"|grep -i -A2 "Medelvärde hittills i år"|tail -n1|awk 'BEGIN{FS="[<|>]"} {gsub(",", "."); printf("%f\n", $7*0.27)}' |
ByteBuffer.allocate(4).putInt(integer).array() |