Profile | download (kb/s) | upload (kb/s) | latency (ms) |
---|---|---|---|
Native | 0 | 0 | 0 |
GPRS | 50 | 20 | 500 |
56K Dial-up | 50 | 30 | 120 |
Mobile EDGE | 240 | 200 | 840 |
2G Regular | 250 | 50 | 300 |
2G Good | 450 | 150 | 150 |
3G Slow | 780 | 330 | 200 |
Discover gists
public class DelayStartAnnotation(IResource waitForResource) : IResourceAnnotation | |
{ | |
public IResource WaitForResource { get; } = waitForResource; | |
} |
CREATE OR REPLACE FUNCTION EXTRACT_RULE_ID(versionedRuleId STRING) | |
RETURNS STRING | |
LANGUAGE JAVASCRIPT | |
AS 'return versionedRuleId.substring(0, versionedRuleId.indexOf("@") - 1);'; | |
CREATE OR REPLACE FUNCTION GET_DISTINCT_RULES_MATCHED(arr1 ARRAY, arr2 ARRAY) | |
RETURNS ARRAY | |
LANGUAGE JAVASCRIPT | |
AS ' | |
var result = []; |
⇐ back to the gist-blog at jrw.fi
Or, 16 cool things you may not have known your stylesheets could do. I'd rather have kept it to a nice round number like 10, but they just kept coming. Sorry.
I've been using SCSS/SASS for most of my styling work since 2009, and I'm a huge fan of Compass (by the great @chriseppstein). It really helped many of us through the darkest cross-browser crap. Even though browsers are increasingly playing nice with CSS, another problem has become very topical: managing the complexity in stylesheets as our in-browser apps get larger and larger. SCSS is an indispensable tool for dealing with this.
This isn't an introduction to the language by a long shot; many things probably won't make sense unless you have some SCSS under your belt already. That said, if you're not yet comfy with the basics, check out the aweso
"""Hello world, with a genetic algorithm. | |
https://twitter.com/matthen2/status/1769368467067621791 | |
""" | |
import random | |
import time | |
from dataclasses import dataclass | |
from itertools import chain | |
from typing import Iterable, List |
if [ ! -f .env ] | |
then | |
export $(cat .env | xargs) | |
fi |
Do this in cases when you dont want to change the os-level settings, but only want to disable the OOM killer for a single process. This is useful when youre on a shared machine/server.
The OOM killer uses the process level metric called oom_score_adj
to decide if/when to kill a process.
This file is present in /proc/$pid/oom_score_adj
. The oom_score_adj can vary from -1000
to 1000
, by default it is 0.
You can add a large negative score to this file to reduce the probability of your process getting picked and terminated by OOM killer. When you set it to -1000, it can use 100% memory and still avoid getting terminated by OOM killer.
import subprocess | |
import dspy | |
### Note this code is not tested, and likely includes errors that need to be refined. | |
class IterativeCodeRefinement(dspy.Module): | |
def __init__(self): | |
super().__init__() | |
self.generate_pseudocode = dspy.ChainOfThought("task -> pseudocode") |
# Get-ADGroupMembership.ps1 | |
# Written by Bill Stewart | |
#requires -version 2 | |
# Version history: | |
# 1.0 (2019-12-02) | |
# * Initial version. Only searches the current domain. | |
<# |