Discover gists
This file contains 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 logging | |
import time | |
from contextlib import contextmanager | |
from collections import defaultdict | |
import numpy as np | |
import torch | |
import matplotlib.pyplot as plt | |
# --- External libraries --- |
This file contains 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
<main class="shop-container"> | |
<div class="shop-header"> | |
<h1>Leafy Haven: Indoor Plants</h1> | |
<p>Transform your space into a green sanctuary with our carefully curated selection of indoor plants. Each plant is chosen for its unique characteristics and air-purifying qualities.</p> | |
</div> | |
<div class="categories"> | |
<button class="category-button active" data-category="all">All Plants</button> | |
<button class="category-button" data-category="low-light">Low Light</button> | |
<button class="category-button" data-category="air-purifying">Air Purifying</button> |
This file contains 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
Log uploaded on Tuesday, February 11, 2025, 7:23:26 PM | |
Loaded mods: | |
Prepatcher(zetrith.prepatcher): 0Harmony(2.3.3), 0PrepatcherAPI(1.2.0), 0PrepatcherDataAssembly(1.0.0), PrepatcherImpl(1.0.0), Prestarter(1.0.0) | |
Harmony(brrainz.harmony)[mv:2.3.1.0]: 0Harmony(2.3.3), HarmonyMod(2.3.1) | |
Fishery - Modding Library(bs.fishery): 0PrepatcherAPI(1.2.0), 1Fishery(0.6.1), System.Runtime.CompilerServices.Unsafe(av:6.0.0,fv:6.0.21.52210) | |
Core(Ludeon.RimWorld): (no assemblies) | |
Performance Fish(bs.performance): PerformanceFish(0.6.2) | |
Royalty(Ludeon.RimWorld.Royalty): (no assemblies) | |
Vanilla Backgrounds Expanded(vanillaexpanded.backgrounds): VBE(1.0.0) | |
Ideology(Ludeon.RimWorld.Ideology): (no assemblies) |
This file contains 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
rows, cols = image.shape[:2] | |
pts1 = np.float32([[50,50],[200,50],[50,200]]) | |
pts2 = np.float32([[10,100],[200,50],[100,250]]) | |
M = cv2.getAffineTransform(pts1, pts2) | |
affine_transformed = cv2.warpAffine(image, M, (cols, rows)) |
This file contains 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
package main | |
import ( | |
"fmt" | |
"log" | |
"net/url" | |
"os" | |
"strings" | |
"github.com/spf13/cobra" |
This file contains 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
2025-02-11 18:17:49,794 2084 [DEBUG] - XmlConfiguration is now operational | |
2025-02-11 18:17:55,901 2084 [DEBUG] - Adding new type 'CygwinService' for type 'IAlternativeSourceRunner' from assembly 'choco' | |
2025-02-11 18:17:55,991 2084 [DEBUG] - Adding new type 'CygwinService' for type 'IInstallSourceRunner' from assembly 'choco' | |
2025-02-11 18:17:56,103 2084 [DEBUG] - Adding new type 'PythonService' for type 'IAlternativeSourceRunner' from assembly 'choco' | |
2025-02-11 18:17:56,212 2084 [DEBUG] - Adding new type 'PythonService' for type 'IListSourceRunner' from assembly 'choco' | |
2025-02-11 18:17:56,307 2084 [DEBUG] - Adding new type 'PythonService' for type 'IInstallSourceRunner' from assembly 'choco' | |
2025-02-11 18:17:56,343 2084 [DEBUG] - Adding new type 'PythonService' for type 'IUninstallSourceRunner' from assembly 'choco' | |
2025-02-11 18:17:56,386 2084 [DEBUG] - Adding new type 'RubyGemsService' for type 'IAlternativeSourceRunner' from assembly 'choco' | |
2025-02-11 18:17:56,492 2084 [DEBUG] - Adding new typ |
This file contains 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
Pipeline still running ... | |
PipelineRun is still running: Tasks Completed: 26 (Failed: 0, Cancelled 0), Incomplete: 1, Skipped: 5 | |
[set-github-started-label : post-comment] + EXTRA_ARGS= | |
[set-github-started-label : post-comment] + [[ ! -z operator-release-pipeline/started ]] | |
[set-github-started-label : post-comment] + EXTRA_ARGS+=' --add-labels operator-release-pipeline/started' | |
[set-github-started-label : post-comment] + [[ ! -z pipeline/trigger-release ]] | |
[set-github-started-label : post-comment] Editing GitHub labels to PR https://github.com/redhat-openshift-ecosystem/certified-operators/pull/5178 | |
[set-github-started-label : post-comment] + EXTRA_ARGS+=' --remove-labels pipeline/trigger-release' | |
[set-github-started-label : post-comment] + [[ true == \t\r\u\e ]] | |
[set-github-started-label : post-comment] + EXTRA_ARGS+=' --remove-matching-namespace-labels' |
This file contains 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
# train_grpo.py | |
import re | |
import torch | |
from datasets import load_dataset, Dataset | |
from transformers import AutoTokenizer, AutoModelForCausalLM | |
from peft import LoraConfig | |
from trl import GRPOConfig, GRPOTrainer | |
# Load and prep dataset |
This file contains 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
#connect | |
# Automatically switch to traffic when closing weak network | |
settings put global wifi_num_of_switch_to_mobile_data_toggle 0 | |
# Turn off weak network detection | |
settings put global wifi_watchdog_poor_network_test_enabled 0 | |
# Turn off weak network detection | |
settings put global network_avoid_bad_wifi 0 | |
#Turn off switching to a better WLAN network | |
settings put global sem_wifi_switch_to_better_wifi_enabled 0 | |
#Disable nearby device scanning |
This file contains 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
const x25519_key = await crypto.subtle.generateKey( | |
{ name: "X25519" }, | |
true, // Extractable | |
["deriveKey", "deriveBits"] | |
); | |
// Export the keys | |
const privateKeyJwk = await crypto.subtle.exportKey("pkcs8", x25519_key.privateKey); | |
const publicKeyJwk = await crypto.subtle.exportKey("spki", x25519_key.publicKey); |