FP8 Model Conversion

  • Source: https://huggingface.co/Comfy-Org/Qwen3.5/text_encoders
  • Original File(s): qwen3.5_2b_bf16.safetensors
  • Original Format: safetensors
  • FP8 Format: E5M2
  • FP8 File: qwen3.5_2b_bf16-fp8-e5m2.safetensors

Usage

from safetensors.torch import load_file
import torch

# Load FP8 model
fp8_state = load_file("qwen3.5_2b_bf16-fp8-e5m2.safetensors")

# Convert tensors back to float32 for computation (auto-converted by PyTorch)
model.load_state_dict(fp8_state)

Note: FP8 tensors are automatically converted to float32 when loaded in PyTorch. Requires PyTorch ≥ 2.1 for FP8 support.

Statistics

  • Total tensors: 632
  • Converted to FP8: 632
  • Skipped (non-float): 0
Downloads last month
4
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support