Timer-S1 是字节跳动(bytedance-research)开源的时序预测基础模型,
基于 LLM 架构(24 层 Transformer),支持零样本时序预测。
本仓库为 华为昇腾 NPU(Ascend 910B 系列)推理适配版,支持 npu:0 一键推理。
| 项目 | 说明 |
|---|---|
| 模型 | bytedance-research/Timer-S1 |
| 架构 | Timer-S1(LLM 时序基础模型,trust_remote_code) |
| 规模 | 8303.7 M 参数(BF16,4 分片共 15.5GB) |
| 输入 | 时序连续值 (1, 512) |
| 输出 | logits (1, 9, 16) |
| 任务 | 时间序列预测(零样本) |
| 原始仓库 | bytedance-research/Timer-S1 |
| License | Apache-2.0 |
| 项目 | 要求 |
|---|---|
| 硬件 | Ascend 910B 系列(≥1 卡,本仓库基于 910B4 验证) |
| CANN | ≥ 8.0 |
| Python | 3.10 – 3.11 |
| torch / torch_npu | 2.9.0 / 2.9.0.post2 |
| transformers | 5.15.0 |
注意:本仓库不包含模型权重文件(4 个分片共约 15.5GB)。
权重请从以下镜像获取:
git clone --depth 1 https://gitcode.com/hf_mirrors/bytedance-research/Timer-S1.git model_src
# 或用 hf-mirror 逐个下载 model-0000X-of-00004.safetensorspython3 inference.py --device npu [--model_path ./model_src]$ python3 inference.py --device npu
[info] device = npu:0
[info] model arch : Timer-S1 (时序基础模型)
参数: 8303.7 M
[info] input : 时序 (1, 512)
[info] inference done : 888.9 ms on npu
[info] logits : (1, 9, 16)
[info] 设备确认 : npu:0
[PASS] Timer-S1 NPU inference OK.npu() 迁移即可。DynamicCache.from_legacy_cache /
to_legacy_cache 在新版被移除,推理脚本内已打兼容补丁(monkey-patch)。local_files_only=True + trust_remote_code=True 完全离线。