This file contains hidden or 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 argparse | |
| import csv | |
| import glob | |
| import os | |
| from pathlib import Path | |
| import cv2 | |
| import numpy as np | |
| import torch | |
| from PIL import Image |
This file contains hidden or 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
| # 仮に logs に入れたら以下のように指定 | |
| # --lr_scheduler_type logs.stepwise_linear_decay_lr_scheduler.get_stepwise_linear_decay_lr_scheduler | |
| # --lr_scheduler_args "step_a=50" "step_b=80" "factor_1=1.0" "factor_2=0.1" | |
| # | |
| # step_a までの学習率: 指定した learning_rate * factor_1 | |
| # step_a から step_b まで: 線形に減少(増加) | |
| # step_b からの学習率: 指定した learning_rate * factor_2 | |
| from torch.optim.lr_scheduler import LambdaLR |
This file contains hidden or 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
| # Apache License 2.0 | |
| # 使用法は gist のコメントを見てください | |
| import argparse | |
| import importlib | |
| import json | |
| import os | |
| import random | |
| import time | |
| import traceback | |
| import tomli |
This file contains hidden or 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
| # Apache License 2.0 | |
| # 使用法は gist のコメントを見てください | |
| import time | |
| import argparse | |
| import os | |
| import json | |
| import tomli | |
| import traceback | |
| from typing import Any, Dict, List, Optional, Union, Iterator |
This file contains hidden or 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
| # License: Apache 2.0 | |
| from typing import Dict, Optional | |
| import struct | |
| import json | |
| import numpy as np | |
| import torch | |
This file contains hidden or 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
| # ライセンスは Apache License 2.0 です。 | |
| # お勧めのオプションは: | |
| # --flash_attn --q8_kv_cache --n_gpu_layers <GPUのVRAMに応じて> --n_ctx <VRAMとモデルのcontext lengthに応じて> | |
| import argparse | |
| import random | |
| import msvcrt # Windowsの場合 | |
| import toml | |
| from typing import List, Optional, Union, Iterator |
This file contains hidden or 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
| # client_v4.py | |
| """ | |
| Message Box MCP Client | |
| インストール方法等はserver_v4.pyを参照。 | |
| ## 使用法 | |
| メッセージ取得: |
OlderNewer