bojian1 commited on
Commit
da5307d
·
verified ·
1 Parent(s): 8add876

Upload UniFreq-tiny inference checkpoint

Browse files
Files changed (3) hide show
  1. README.md +37 -0
  2. config.json +38 -0
  3. model.safetensors +3 -0
README.md ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - time-series
4
+ - fault-diagnosis
5
+ - pytorch
6
+ - safetensors
7
+ ---
8
+
9
+ # UniFreq-tiny
10
+
11
+ Inference checkpoint for the **tiny** UniFreq time-frequency encoder.
12
+
13
+ - Time embedding dimension: `64`
14
+ - Frequency embedding dimension: `64`
15
+ - Fused feature dimension: `128`
16
+ - Frequency bins: `800`
17
+ - Input window duration: `0.1` seconds
18
+
19
+ ## Usage
20
+
21
+ ```python
22
+ import numpy as np
23
+ import torch
24
+ from model import PHMFDProcessor, load_model
25
+
26
+ model, config = load_model("bojian1/UniFreq-tiny")
27
+ processor = PHMFDProcessor(config)
28
+ batch = processor([np.random.randn(2048).astype("float32")])
29
+
30
+ with torch.inference_mode():
31
+ features = model(batch)
32
+ ```
33
+
34
+ Inference code: https://github.com/Bojian-Chen/UniFreq
35
+
36
+ This repository contains inference artifacts only: `config.json` and
37
+ `model.safetensors`.
config.json ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "TimeFrequencyBackbone"
4
+ ],
5
+ "depth": 4,
6
+ "dropout": 0.1,
7
+ "embed_dim": 64,
8
+ "freq_data_normalize": "sample_minmax",
9
+ "freq_fft_source_normalize": "none",
10
+ "freq_max_bins": 800,
11
+ "freq_patch_include_log_position": true,
12
+ "freq_patch_projection": "conv",
13
+ "freq_patch_size": 16,
14
+ "freq_pope_harmonics": "2,3,4,5",
15
+ "freq_pope_sigma": 0.08,
16
+ "freq_position_encoding": "harmonic_pope",
17
+ "freq_rope_base": 1000.0,
18
+ "freq_tail_stats": true,
19
+ "freq_tokenizer": "global_fft",
20
+ "freq_transformer_layers": 4,
21
+ "heads": 2,
22
+ "input_length_mode": "preserve",
23
+ "input_target_len": 0,
24
+ "model_arch": "timefreq",
25
+ "model_name": "UniFreq-tiny",
26
+ "model_type": "phmfd-timefreq",
27
+ "num_channels": 1,
28
+ "num_classes": 0,
29
+ "patch_fft_num_queries": 1,
30
+ "patch_fft_window": "rect",
31
+ "source_run": "timefreq_tiny_seed42_800bins",
32
+ "time_data_normalize": "none",
33
+ "time_patch_attention": "mha",
34
+ "time_patch_seconds": 0.00625,
35
+ "time_transformer_layers": 4,
36
+ "timefreq_fusion": "concat",
37
+ "window_seconds": 0.1
38
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:85835cbfb885dfdcc37f4bbbc0c125c5ceebbb27770962c08bbb43df42e395c7
3
+ size 1694300