Skip to content

Instantly share code, notes, and snippets.

@geocine
geocine / convert_original_stable_diffusion_to_diffusers_fix.py
Created December 26, 2022 18:50
convert_original_stable_diffusion_to_diffusers_fix.py
# coding=utf-8
# Copyright 2022 The HuggingFace Inc. team.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# Script for converting a HF Diffusers saved pipeline to a Stable Diffusion checkpoint.
# *Only* converts the UNet, VAE, and Text Encoder.
# Does not convert optimizer state or any other thing.
# Written by jachiam
import argparse
import os.path as osp
import torch
@mrowrpurr
mrowrpurr / Papyrus Project Template File.ppj.md
Last active October 22, 2024 15:56
VS Code File Templates for Papyrus

Note: Check to verify the path in these files matches your Skyrim install folder (else change the paths)

To use these templates with the Papyrus Extension for Visual Studio Code:

  1. Install the extension
  2. Download the latest version of Pyro
  3. Browse to C:\Users\[YOUR USER]\.vscode\extensions\joelday.papyrus-lang-vscode-*\
  4. Delete everything in the pyro folder and replace it with the freshly downloaded version of pyro
  5. Open up the resources/sse folder
  6. Open skyrimse.ppj and replace the contents with the contents of the skyrimse.ppj in this Gist
@gboudreau
gboudreau / AuthyToOtherAuthenticator.md
Last active November 16, 2024 21:03 — forked from Ingramz/AuthyToOtherAuthenticator.md
Export TOTP tokens from Authy

Exporting your 2FA tokens from Authy to transfer them into another 2FA application

IMPORTANT - Update regarding deprecation of Authy desktop apps

Past August 2024, Authy stopped supported the desktop version of their apps:
See Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August for details.

And indeed, after a while, Authy changed something in their backend which now prevents the old desktop app from logging in. If you are already logged in, then you are in luck, and you can follow the instructions below to export to tokens.

If you are not logged in anymore, but can find a backup of the necessary files, then restore those files, and re-install Authy 2.2.3 following the instructions below, and it should work as expected.

@dcode
dcode / GitHub Flavored Asciidoc (GFA).adoc
Last active October 12, 2024 11:16
Demo of some useful tips for using Asciidoc on GitHub

GitHub Flavored Asciidoc (GFA)

@flowerinthenight
flowerinthenight / rest_client_svr_console.cs
Last active September 18, 2022 10:12
A simple REST client/server console app in C#.
using CommandLine;
using CommandLine.Text;
using Grapevine;
using Grapevine.Client;
using Grapevine.Server;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Collections.Specialized;
using System.Diagnostics;
@epixoip
epixoip / 8x1080.md
Last active November 3, 2024 15:42
8x Nvidia GTX 1080 Hashcat Benchmarks
@thomasdarimont
thomasdarimont / DefaultMethodProxyExample.java
Last active July 23, 2024 21:25
Examples for dynamic creating instances of interfaces with only default methods
package labs;
import java.lang.invoke.MethodHandles;
import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;
import java.util.Arrays;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
import java.util.stream.Collectors;
@glombard
glombard / ClipboardNotification.cs
Created December 16, 2013 12:34
Monitor Clipboard changes in C# using AddClipboardFormatListener / WM_CLIPBOARDUPDATE. See Clipboard class: http://msdn.microsoft.com/en-us/library/system.windows.clipboard(v=vs.110).aspx
// from: http://stackoverflow.com/questions/2226920/how-to-monitor-clipboard-content-changes-in-c
/// <summary>
/// Provides notifications when the contents of the clipboard is updated.
/// </summary>
public sealed class ClipboardNotification
{
/// <summary>
/// Occurs when the contents of the clipboard is updated.
/// </summary>
@yetithefoot
yetithefoot / stuns
Last active October 17, 2024 21:42 — forked from zziuni/stuns
STUN+TURN servers list
{url:'stun:stun01.sipphone.com'},
{url:'stun:stun.ekiga.net'},
{url:'stun:stun.fwdnet.net'},
{url:'stun:stun.ideasip.com'},
{url:'stun:stun.iptel.org'},
{url:'stun:stun.rixtelecom.se'},
{url:'stun:stun.schlund.de'},
{url:'stun:stun.l.google.com:19302'},
{url:'stun:stun1.l.google.com:19302'},
{url:'stun:stun2.l.google.com:19302'},