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 discord | |
import asyncio | |
import logging | |
import logging.handlers | |
from openai import OpenAI | |
from discord import app_commands | |
from discord import Message | |
KIMITOKEN = "" | |
DISCORD_BOT_TOKEN = "" |
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 os | |
import random | |
import math, warnings | |
from copy import deepcopy | |
import numpy as np | |
import lightning | |
import torch | |
import torch.nn as nn | |
import torch.nn.functional as F |
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 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 sys | |
import torch | |
import torch.nn as nn | |
import torch.nn.functional as F | |
import clip | |
import pandas as pd | |
import hashlib | |
import numpy | |
import cv2 | |
from tqdm.auto import tqdm |
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
# | |
# NAFNet Image Upscaler | |
# Mikubill, MIT License | |
# | |
# Usage: | |
# python nafnet.py -i [path_to_images] | |
# | |
# Parameters: | |
# -m, --model: Specifies the model to use. The default is NAFNet-REDS-width64. | |
# -i, --input: Path to the directory containing images to upscale. This parameter is required. |
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 os | |
import openai | |
import gradio as gr | |
openai.api_key = os.environ['OPENAI_KEY'] | |
supportLanguages = [ | |
["auto", "auto"], | |
["粤语", "yue"], | |
["古文", "wyw"], |
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 os | |
import json | |
import openai | |
import requests | |
from copy import deepcopy | |
from datetime import date | |
today = date.today() | |
openai.api_key = "" |
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 os.path | |
import re | |
import tempfile | |
import argparse | |
import glob | |
import zipfile | |
import deepdanbooru as dd | |
import tensorflow as tf | |
import numpy as np |
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
'''Simple script to finetune a stable-diffusion model''' | |
import argparse | |
import contextlib | |
import copy | |
import gc | |
import hashlib | |
import itertools | |
import json | |
import math |
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
#!/bin/sh | |
set -e | |
command_exists() { | |
command -v "$@" > /dev/null 2>&1 | |
} | |
user="$(id -un 2>/dev/null || true)" | |
# username="neko-$(tr -dc 0-9a-f </dev/urandom | head -c 2)" | |
# original="$(hostname)" |
NewerOlder