Skip to content

Instantly share code, notes, and snippets.

View speedcell4's full-sized avatar

Yiran Wang speedcell4

View GitHub Profile
from typing import Any
import torch
import triton
import triton.language as tl
from torch import Tensor
from torch.nn import functional as F
from torch.testing import assert_close
@speedcell4
speedcell4 / env.sh
Last active December 29, 2025 01:14
New Python Env
python3 -m pip install pip setuptools pytest hypothesis --no-cache-dir
python3 -m pip install torch torchvision torchaudio triton transformers datasets tokenizers liger-kernel --no-cache-dir
python3 -m pip install packaging ninja aku chew torchdevice torchgather torchnyen --no-cache-dir
MAX_JOBS=$(nproc) python3 -m pip install flash-attn --no-build-isolation --no-cache-dir -v
python3 -m pip install git+https://github.com/speedcell4/torchlatent.git@develop
python3 -m pip install git+https://github.com/speedcell4/torchglyph.git@develop
python3 -m pip install git+https://github.com/speedcell4/torchrua.git@develop
python3 -m pip install git+https://github.com/speedcell4/torchshya.git --no-deps