Scene-text visual-style encoder (Chinese-specialized)

Chinese-specialized DINOv2 ViT-S/14 scene-text style encoder. It represents typography and visual appearance, not text identity. The opaque repository name is not an access-control mechanism; this model is intentionally public.

Outputs

  • z_global [N,256]: overall typography and appearance.
  • z_font [N,128]: font/typography-oriented representation.
  • z_appearance [N,128]: fill, stroke, shadow, and opacity-oriented representation.
  • style_tokens [N,8,384]: local research tokens; not validated as generator conditioning.

The three z_* tensors are L2-normalized. Supply a tightly cropped text instance or line. Preprocessing preserves aspect ratio and pads to 112 x 448.

Install and use

git clone https://github.com/zqpresent/aaazhouquandecangku.git
cd aaazhouquandecangku
python -m pip install -e .
opaque-encoder download zqpresent/m2d8e6c4f1a9b7350e42 --local-dir weights
opaque-encoder encode --model weights --input crops --output styles.npz --device cpu --local-files-only

The complete fine-tuned backbone is included; no separate backbone download is required. The loader checks the SHA-256 value in config.json.

Training scope and limitations

40,000 counterfactual groups / 640,000 rendered scene views. Font families, Chinese character partitions, and background sources used for final evaluation were held out from task training. Best suited to the controlled Chinese synthetic domain. English retention is weaker; use the bilingual artifact when both scripts are needed. The encoder does not perform OCR. Synthetic retrieval evidence is not real-world accuracy, and low content/background probe scores do not prove zero leakage.

verification.json records source-to-export numerical parity. The source training checkpoint, optimizer state, classifiers, data manifests, and local paths are not included in the inference weights.

Downloads last month
11
Safetensors
Model size
23.3M params
Tensor type
F32
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support