Skip to content

Instantly share code, notes, and snippets.

View tsukumijima's full-sized avatar
📺
TTS & DTV

tsukumi tsukumijima

📺
TTS & DTV
View GitHub Profile
[
{
"word": "Asshole",
"kana": "アスホール",
"meaning": "いやな奴(Ass=お尻、Hole=穴)",
"notice": "「うざい野郎」「ろくでなし」"
},
{
"word": "あばずれ",
"kana": "あばずれ",
@yyya-nico
yyya-nico / README.md
Last active May 31, 2024 18:48
KonomiTVですべての地上波チャンネルを同時視聴する

KonomiTVですべての地上波チャンネルを同時視聴する

KonomiTVにファイルを足すことで、地上波多チャンネル同時視聴ができるかもしれない。
当然チューナーは必要数用意
まずフォルダーを以下の場所に作る。

  • {KonomiTVインストールフォルダー}/client/dist/wholech/
  • {KonomiTVインストールフォルダー}/client/dist/wholech/css/
  • {KonomiTVインストールフォルダー}/client/dist/wholech/js/

htmlファイルはwholechフォルダー、cssファイルはcssフォルダー、jsファイルはjsフォルダーに置く。

@subaru-shoji
subaru-shoji / aivis-dataset_and_style-bert-vits2.ipynb
Created January 2, 2024 13:30
aivis-dataset_and_style-bert-vits2.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@litagin02
litagin02 / simple_merge.py
Last active February 25, 2024 16:13
Bert-VITS2のモデルマージするやつ(声音・感情表現それぞれを取っ替えたり混ぜたり)
import os
import gradio as gr
import torch
from infer import get_net_g, infer
import utils
voice_keys = ["dec", "flow"]
speech_style_keys = ["enc_p"]
# MIT License
# This code will run on VRAM 12GB+ GPU such as T4, RTX 3060
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
from langchain.text_splitter import RecursiveCharacterTextSplitter
from langchain.document_loaders import PyPDFLoader
from langchain.vectorstores import FAISS
from langchain.chains import RetrievalQA
from langchain.embeddings import HuggingFaceEmbeddings
from langchain.llms.huggingface_pipeline import HuggingFacePipeline
@opparco
opparco / debug-tokenizer-vicuna-13b.py
Created August 21, 2023 04:59
debug tokenizer of lmsys/vicuna-13b-v1.3
#
# debug tokenizer of lmsys/vicuna-13b-v1.3
#
from transformers import AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("lmsys/vicuna-13b-v1.3")
def encode_decode(string: str):
@opparco
opparco / weblab_10b.py
Last active August 20, 2023 10:20
correct vocab of matsuo-lab/weblab-10b
#
# correct vocab of matsuo-lab/weblab-10b
#
vocab = {}
# 95 -> (none)
# 96 -> \xa1
# ...
# 107 -> \xac
/*
https://github.com/karpathy/llama2.c/blob/master/run.c
GPT-4による解説
このプログラムは、Transformerネットワークを実装し、トークン化されたテキスト入力から次の最も適したトークンを予測します。具体的には以下のようになります:
先頭の部分は、TransformerWeightsとRunStateという2つのデータ構造とそれらの関連するメモリの管理を含みます。
Configという構造体は、トランスフォーマーネットワークのパラメータを保持します。
次に、指定されたチェックポイントファイルから重みを初期化する関数があります。この関数は、チェックポイントファイルからトランスフォーマーネットワークの重みを読み込み、適切に配置します。
@adrienbrault
adrienbrault / llama2-mac-gpu.sh
Last active April 8, 2025 13:49
Run Llama-2-13B-chat locally on your M1/M2 Mac with GPU inference. Uses 10GB RAM. UPDATE: see https://twitter.com/simonw/status/1691495807319674880?s=20
# Clone llama.cpp
git clone https://github.com/ggerganov/llama.cpp.git
cd llama.cpp
# Build it
make clean
LLAMA_METAL=1 make
# Download model
export MODEL=llama-2-13b-chat.ggmlv3.q4_0.bin
@younesbelkada
younesbelkada / finetune_llama_v2.py
Last active April 7, 2025 18:27
Fine tune Llama v2 models on Guanaco Dataset
# coding=utf-8
# Copyright 2023 The HuggingFace Inc. team. All rights reserved.
#
# 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