Spaces:
Runtime error
Runtime error
try
#1
by Utiuzhnikov - opened
- requirements.txt +3 -9
- src/model/config.json +0 -54
- src/model/id2label.json +0 -13
- src/model/label2id.json +0 -13
- src/model/label_full.json +0 -13
- src/model/model.safetensors +0 -3
- src/model/tokenizer.json +0 -0
- src/model/tokenizer_config.json +0 -14
- src/model_v2/config.json +0 -277
- src/model_v2/id2label.json +0 -124
- src/model_v2/label2id.json +0 -124
- src/model_v2/label_full.json +0 -130
- src/model_v2/model-00001-of-00003.safetensors +0 -3
- src/model_v2/model-00002-of-00003.safetensors +0 -3
- src/model_v2/model-00003-of-00003.safetensors +0 -3
- src/model_v2/model.safetensors.index.json +0 -209
- src/model_v2/tokenizer.json +0 -0
- src/model_v2/tokenizer_config.json +0 -21
- src/streamlit_app.py +34 -328
requirements.txt
CHANGED
|
@@ -1,9 +1,3 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
scikit-learn>=1.0.0
|
| 5 |
-
numpy>=1.24.0
|
| 6 |
-
pandas>=1.5.0
|
| 7 |
-
matplotlib>=3.5.0
|
| 8 |
-
streamlit>=1.20.0
|
| 9 |
-
accelerate>=0.20.0
|
|
|
|
| 1 |
+
altair
|
| 2 |
+
pandas
|
| 3 |
+
streamlit
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model/config.json
DELETED
|
@@ -1,54 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"activation": "gelu",
|
| 3 |
-
"architectures": [
|
| 4 |
-
"DistilBertForSequenceClassification"
|
| 5 |
-
],
|
| 6 |
-
"attention_dropout": 0.1,
|
| 7 |
-
"bos_token_id": null,
|
| 8 |
-
"dim": 768,
|
| 9 |
-
"dropout": 0.1,
|
| 10 |
-
"dtype": "float32",
|
| 11 |
-
"eos_token_id": null,
|
| 12 |
-
"hidden_dim": 3072,
|
| 13 |
-
"id2label": {
|
| 14 |
-
"0": "math.AC",
|
| 15 |
-
"1": "cs.CV",
|
| 16 |
-
"2": "cs.AI",
|
| 17 |
-
"3": "cs.SY",
|
| 18 |
-
"4": "math.GR",
|
| 19 |
-
"5": "cs.CE",
|
| 20 |
-
"6": "cs.PL",
|
| 21 |
-
"7": "cs.IT",
|
| 22 |
-
"8": "cs.DS",
|
| 23 |
-
"9": "cs.NE",
|
| 24 |
-
"10": "math.ST"
|
| 25 |
-
},
|
| 26 |
-
"initializer_range": 0.02,
|
| 27 |
-
"label2id": {
|
| 28 |
-
"cs.AI": 2,
|
| 29 |
-
"cs.CE": 5,
|
| 30 |
-
"cs.CV": 1,
|
| 31 |
-
"cs.DS": 8,
|
| 32 |
-
"cs.IT": 7,
|
| 33 |
-
"cs.NE": 9,
|
| 34 |
-
"cs.PL": 6,
|
| 35 |
-
"cs.SY": 3,
|
| 36 |
-
"math.AC": 0,
|
| 37 |
-
"math.GR": 4,
|
| 38 |
-
"math.ST": 10
|
| 39 |
-
},
|
| 40 |
-
"max_position_embeddings": 512,
|
| 41 |
-
"model_type": "distilbert",
|
| 42 |
-
"n_heads": 12,
|
| 43 |
-
"n_layers": 6,
|
| 44 |
-
"output_past": true,
|
| 45 |
-
"pad_token_id": 0,
|
| 46 |
-
"problem_type": "single_label_classification",
|
| 47 |
-
"qa_dropout": 0.1,
|
| 48 |
-
"seq_classif_dropout": 0.2,
|
| 49 |
-
"sinusoidal_pos_embds": false,
|
| 50 |
-
"tie_weights_": true,
|
| 51 |
-
"tie_word_embeddings": true,
|
| 52 |
-
"transformers_version": "5.5.0",
|
| 53 |
-
"vocab_size": 28996
|
| 54 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model/id2label.json
DELETED
|
@@ -1,13 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"0": "math.AC",
|
| 3 |
-
"1": "cs.CV",
|
| 4 |
-
"2": "cs.AI",
|
| 5 |
-
"3": "cs.SY",
|
| 6 |
-
"4": "math.GR",
|
| 7 |
-
"5": "cs.CE",
|
| 8 |
-
"6": "cs.PL",
|
| 9 |
-
"7": "cs.IT",
|
| 10 |
-
"8": "cs.DS",
|
| 11 |
-
"9": "cs.NE",
|
| 12 |
-
"10": "math.ST"
|
| 13 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model/label2id.json
DELETED
|
@@ -1,13 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"math.AC": 0,
|
| 3 |
-
"cs.CV": 1,
|
| 4 |
-
"cs.AI": 2,
|
| 5 |
-
"cs.SY": 3,
|
| 6 |
-
"math.GR": 4,
|
| 7 |
-
"cs.CE": 5,
|
| 8 |
-
"cs.PL": 6,
|
| 9 |
-
"cs.IT": 7,
|
| 10 |
-
"cs.DS": 8,
|
| 11 |
-
"cs.NE": 9,
|
| 12 |
-
"math.ST": 10
|
| 13 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model/label_full.json
DELETED
|
@@ -1,13 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"math.AC": "Mathematics: Commutative Algebra",
|
| 3 |
-
"cs.CV": "Computer Science: Computer Vision",
|
| 4 |
-
"cs.AI": "Computer Science: Artificial Intelligence",
|
| 5 |
-
"cs.SY": "Computer Science: Systems & Control",
|
| 6 |
-
"math.GR": "Mathematics: Group Theory",
|
| 7 |
-
"cs.CE": "Computer Science: Computational Engineering",
|
| 8 |
-
"cs.PL": "Computer Science: Programming Languages",
|
| 9 |
-
"cs.IT": "Computer Science: Information Theory",
|
| 10 |
-
"cs.DS": "Computer Science: Data Structures & Algorithms",
|
| 11 |
-
"cs.NE": "Computer Science: Neural & Evolutionary Computing",
|
| 12 |
-
"math.ST": "Mathematics: Statistics Theory"
|
| 13 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model/model.safetensors
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:424b45ffb940c6391d3acc08474a706c2b83c3b49c57db9ba7fbdbaa0698d8cd
|
| 3 |
-
size 263172372
|
|
|
|
|
|
|
|
|
|
|
|
src/model/tokenizer.json
DELETED
|
The diff for this file is too large to render.
See raw diff
|
|
|
src/model/tokenizer_config.json
DELETED
|
@@ -1,14 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"backend": "tokenizers",
|
| 3 |
-
"cls_token": "[CLS]",
|
| 4 |
-
"do_lower_case": false,
|
| 5 |
-
"is_local": false,
|
| 6 |
-
"mask_token": "[MASK]",
|
| 7 |
-
"model_max_length": 512,
|
| 8 |
-
"pad_token": "[PAD]",
|
| 9 |
-
"sep_token": "[SEP]",
|
| 10 |
-
"strip_accents": null,
|
| 11 |
-
"tokenize_chinese_chars": true,
|
| 12 |
-
"tokenizer_class": "BertTokenizer",
|
| 13 |
-
"unk_token": "[UNK]"
|
| 14 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/config.json
DELETED
|
@@ -1,277 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"add_cross_attention": false,
|
| 3 |
-
"architectures": [
|
| 4 |
-
"BertForSequenceClassification"
|
| 5 |
-
],
|
| 6 |
-
"attention_probs_dropout_prob": 0.1,
|
| 7 |
-
"bos_token_id": null,
|
| 8 |
-
"classifier_dropout": null,
|
| 9 |
-
"dtype": "float32",
|
| 10 |
-
"eos_token_id": null,
|
| 11 |
-
"hidden_act": "gelu",
|
| 12 |
-
"hidden_dropout_prob": 0.1,
|
| 13 |
-
"hidden_size": 768,
|
| 14 |
-
"id2label": {
|
| 15 |
-
"0": "astro-ph.CO",
|
| 16 |
-
"1": "astro-ph.EP",
|
| 17 |
-
"2": "astro-ph.GA",
|
| 18 |
-
"3": "astro-ph.HE",
|
| 19 |
-
"4": "astro-ph.IM",
|
| 20 |
-
"5": "astro-ph.SR",
|
| 21 |
-
"6": "cond-mat.dis-nn",
|
| 22 |
-
"7": "cond-mat.mes-hall",
|
| 23 |
-
"8": "cond-mat.mtrl-sci",
|
| 24 |
-
"9": "cond-mat.quant-gas",
|
| 25 |
-
"10": "cond-mat.soft",
|
| 26 |
-
"11": "cond-mat.stat-mech",
|
| 27 |
-
"12": "cond-mat.str-el",
|
| 28 |
-
"13": "cond-mat.supr-con",
|
| 29 |
-
"14": "cs.AI",
|
| 30 |
-
"15": "cs.CC",
|
| 31 |
-
"16": "cs.CG",
|
| 32 |
-
"17": "cs.CL",
|
| 33 |
-
"18": "cs.CR",
|
| 34 |
-
"19": "cs.CV",
|
| 35 |
-
"20": "cs.CY",
|
| 36 |
-
"21": "cs.DB",
|
| 37 |
-
"22": "cs.DC",
|
| 38 |
-
"23": "cs.DM",
|
| 39 |
-
"24": "cs.DS",
|
| 40 |
-
"25": "cs.GT",
|
| 41 |
-
"26": "cs.HC",
|
| 42 |
-
"27": "cs.IR",
|
| 43 |
-
"28": "cs.IT",
|
| 44 |
-
"29": "cs.LG",
|
| 45 |
-
"30": "cs.LO",
|
| 46 |
-
"31": "cs.NE",
|
| 47 |
-
"32": "cs.NI",
|
| 48 |
-
"33": "cs.PL",
|
| 49 |
-
"34": "cs.RO",
|
| 50 |
-
"35": "cs.SD",
|
| 51 |
-
"36": "cs.SE",
|
| 52 |
-
"37": "cs.SI",
|
| 53 |
-
"38": "cs.SY",
|
| 54 |
-
"39": "econ.EM",
|
| 55 |
-
"40": "econ.GN",
|
| 56 |
-
"41": "econ.TH",
|
| 57 |
-
"42": "eess.AS",
|
| 58 |
-
"43": "eess.IV",
|
| 59 |
-
"44": "eess.SP",
|
| 60 |
-
"45": "eess.SY",
|
| 61 |
-
"46": "gr-qc",
|
| 62 |
-
"47": "hep-ex",
|
| 63 |
-
"48": "hep-lat",
|
| 64 |
-
"49": "hep-ph",
|
| 65 |
-
"50": "hep-th",
|
| 66 |
-
"51": "math-ph",
|
| 67 |
-
"52": "math.AC",
|
| 68 |
-
"53": "math.AG",
|
| 69 |
-
"54": "math.AP",
|
| 70 |
-
"55": "math.AT",
|
| 71 |
-
"56": "math.CA",
|
| 72 |
-
"57": "math.CO",
|
| 73 |
-
"58": "math.CT",
|
| 74 |
-
"59": "math.CV",
|
| 75 |
-
"60": "math.DG",
|
| 76 |
-
"61": "math.DS",
|
| 77 |
-
"62": "math.FA",
|
| 78 |
-
"63": "math.GM",
|
| 79 |
-
"64": "math.GR",
|
| 80 |
-
"65": "math.GT",
|
| 81 |
-
"66": "math.LO",
|
| 82 |
-
"67": "math.MG",
|
| 83 |
-
"68": "math.NA",
|
| 84 |
-
"69": "math.NT",
|
| 85 |
-
"70": "math.OA",
|
| 86 |
-
"71": "math.OC",
|
| 87 |
-
"72": "math.PR",
|
| 88 |
-
"73": "math.QA",
|
| 89 |
-
"74": "math.RA",
|
| 90 |
-
"75": "math.RT",
|
| 91 |
-
"76": "math.SG",
|
| 92 |
-
"77": "math.SP",
|
| 93 |
-
"78": "math.ST",
|
| 94 |
-
"79": "nlin.CD",
|
| 95 |
-
"80": "nlin.PS",
|
| 96 |
-
"81": "nlin.SI",
|
| 97 |
-
"82": "nucl-ex",
|
| 98 |
-
"83": "nucl-th",
|
| 99 |
-
"84": "physics.acc-ph",
|
| 100 |
-
"85": "physics.app-ph",
|
| 101 |
-
"86": "physics.atom-ph",
|
| 102 |
-
"87": "physics.bio-ph",
|
| 103 |
-
"88": "physics.chem-ph",
|
| 104 |
-
"89": "physics.class-ph",
|
| 105 |
-
"90": "physics.comp-ph",
|
| 106 |
-
"91": "physics.flu-dyn",
|
| 107 |
-
"92": "physics.gen-ph",
|
| 108 |
-
"93": "physics.geo-ph",
|
| 109 |
-
"94": "physics.ins-det",
|
| 110 |
-
"95": "physics.med-ph",
|
| 111 |
-
"96": "physics.optics",
|
| 112 |
-
"97": "physics.plasm-ph",
|
| 113 |
-
"98": "physics.soc-ph",
|
| 114 |
-
"99": "q-bio.BM",
|
| 115 |
-
"100": "q-bio.CB",
|
| 116 |
-
"101": "q-bio.GN",
|
| 117 |
-
"102": "q-bio.MN",
|
| 118 |
-
"103": "q-bio.NC",
|
| 119 |
-
"104": "q-bio.OT",
|
| 120 |
-
"105": "q-bio.PE",
|
| 121 |
-
"106": "q-bio.QM",
|
| 122 |
-
"107": "q-bio.SC",
|
| 123 |
-
"108": "q-bio.TO",
|
| 124 |
-
"109": "q-fin.CP",
|
| 125 |
-
"110": "q-fin.GN",
|
| 126 |
-
"111": "q-fin.MF",
|
| 127 |
-
"112": "q-fin.PM",
|
| 128 |
-
"113": "q-fin.PR",
|
| 129 |
-
"114": "q-fin.RM",
|
| 130 |
-
"115": "q-fin.ST",
|
| 131 |
-
"116": "q-fin.TR",
|
| 132 |
-
"117": "quant-ph",
|
| 133 |
-
"118": "stat.AP",
|
| 134 |
-
"119": "stat.CO",
|
| 135 |
-
"120": "stat.ME",
|
| 136 |
-
"121": "stat.ML"
|
| 137 |
-
},
|
| 138 |
-
"initializer_range": 0.02,
|
| 139 |
-
"intermediate_size": 3072,
|
| 140 |
-
"is_decoder": false,
|
| 141 |
-
"label2id": {
|
| 142 |
-
"astro-ph.CO": 0,
|
| 143 |
-
"astro-ph.EP": 1,
|
| 144 |
-
"astro-ph.GA": 2,
|
| 145 |
-
"astro-ph.HE": 3,
|
| 146 |
-
"astro-ph.IM": 4,
|
| 147 |
-
"astro-ph.SR": 5,
|
| 148 |
-
"cond-mat.dis-nn": 6,
|
| 149 |
-
"cond-mat.mes-hall": 7,
|
| 150 |
-
"cond-mat.mtrl-sci": 8,
|
| 151 |
-
"cond-mat.quant-gas": 9,
|
| 152 |
-
"cond-mat.soft": 10,
|
| 153 |
-
"cond-mat.stat-mech": 11,
|
| 154 |
-
"cond-mat.str-el": 12,
|
| 155 |
-
"cond-mat.supr-con": 13,
|
| 156 |
-
"cs.AI": 14,
|
| 157 |
-
"cs.CC": 15,
|
| 158 |
-
"cs.CG": 16,
|
| 159 |
-
"cs.CL": 17,
|
| 160 |
-
"cs.CR": 18,
|
| 161 |
-
"cs.CV": 19,
|
| 162 |
-
"cs.CY": 20,
|
| 163 |
-
"cs.DB": 21,
|
| 164 |
-
"cs.DC": 22,
|
| 165 |
-
"cs.DM": 23,
|
| 166 |
-
"cs.DS": 24,
|
| 167 |
-
"cs.GT": 25,
|
| 168 |
-
"cs.HC": 26,
|
| 169 |
-
"cs.IR": 27,
|
| 170 |
-
"cs.IT": 28,
|
| 171 |
-
"cs.LG": 29,
|
| 172 |
-
"cs.LO": 30,
|
| 173 |
-
"cs.NE": 31,
|
| 174 |
-
"cs.NI": 32,
|
| 175 |
-
"cs.PL": 33,
|
| 176 |
-
"cs.RO": 34,
|
| 177 |
-
"cs.SD": 35,
|
| 178 |
-
"cs.SE": 36,
|
| 179 |
-
"cs.SI": 37,
|
| 180 |
-
"cs.SY": 38,
|
| 181 |
-
"econ.EM": 39,
|
| 182 |
-
"econ.GN": 40,
|
| 183 |
-
"econ.TH": 41,
|
| 184 |
-
"eess.AS": 42,
|
| 185 |
-
"eess.IV": 43,
|
| 186 |
-
"eess.SP": 44,
|
| 187 |
-
"eess.SY": 45,
|
| 188 |
-
"gr-qc": 46,
|
| 189 |
-
"hep-ex": 47,
|
| 190 |
-
"hep-lat": 48,
|
| 191 |
-
"hep-ph": 49,
|
| 192 |
-
"hep-th": 50,
|
| 193 |
-
"math-ph": 51,
|
| 194 |
-
"math.AC": 52,
|
| 195 |
-
"math.AG": 53,
|
| 196 |
-
"math.AP": 54,
|
| 197 |
-
"math.AT": 55,
|
| 198 |
-
"math.CA": 56,
|
| 199 |
-
"math.CO": 57,
|
| 200 |
-
"math.CT": 58,
|
| 201 |
-
"math.CV": 59,
|
| 202 |
-
"math.DG": 60,
|
| 203 |
-
"math.DS": 61,
|
| 204 |
-
"math.FA": 62,
|
| 205 |
-
"math.GM": 63,
|
| 206 |
-
"math.GR": 64,
|
| 207 |
-
"math.GT": 65,
|
| 208 |
-
"math.LO": 66,
|
| 209 |
-
"math.MG": 67,
|
| 210 |
-
"math.NA": 68,
|
| 211 |
-
"math.NT": 69,
|
| 212 |
-
"math.OA": 70,
|
| 213 |
-
"math.OC": 71,
|
| 214 |
-
"math.PR": 72,
|
| 215 |
-
"math.QA": 73,
|
| 216 |
-
"math.RA": 74,
|
| 217 |
-
"math.RT": 75,
|
| 218 |
-
"math.SG": 76,
|
| 219 |
-
"math.SP": 77,
|
| 220 |
-
"math.ST": 78,
|
| 221 |
-
"nlin.CD": 79,
|
| 222 |
-
"nlin.PS": 80,
|
| 223 |
-
"nlin.SI": 81,
|
| 224 |
-
"nucl-ex": 82,
|
| 225 |
-
"nucl-th": 83,
|
| 226 |
-
"physics.acc-ph": 84,
|
| 227 |
-
"physics.app-ph": 85,
|
| 228 |
-
"physics.atom-ph": 86,
|
| 229 |
-
"physics.bio-ph": 87,
|
| 230 |
-
"physics.chem-ph": 88,
|
| 231 |
-
"physics.class-ph": 89,
|
| 232 |
-
"physics.comp-ph": 90,
|
| 233 |
-
"physics.flu-dyn": 91,
|
| 234 |
-
"physics.gen-ph": 92,
|
| 235 |
-
"physics.geo-ph": 93,
|
| 236 |
-
"physics.ins-det": 94,
|
| 237 |
-
"physics.med-ph": 95,
|
| 238 |
-
"physics.optics": 96,
|
| 239 |
-
"physics.plasm-ph": 97,
|
| 240 |
-
"physics.soc-ph": 98,
|
| 241 |
-
"q-bio.BM": 99,
|
| 242 |
-
"q-bio.CB": 100,
|
| 243 |
-
"q-bio.GN": 101,
|
| 244 |
-
"q-bio.MN": 102,
|
| 245 |
-
"q-bio.NC": 103,
|
| 246 |
-
"q-bio.OT": 104,
|
| 247 |
-
"q-bio.PE": 105,
|
| 248 |
-
"q-bio.QM": 106,
|
| 249 |
-
"q-bio.SC": 107,
|
| 250 |
-
"q-bio.TO": 108,
|
| 251 |
-
"q-fin.CP": 109,
|
| 252 |
-
"q-fin.GN": 110,
|
| 253 |
-
"q-fin.MF": 111,
|
| 254 |
-
"q-fin.PM": 112,
|
| 255 |
-
"q-fin.PR": 113,
|
| 256 |
-
"q-fin.RM": 114,
|
| 257 |
-
"q-fin.ST": 115,
|
| 258 |
-
"q-fin.TR": 116,
|
| 259 |
-
"quant-ph": 117,
|
| 260 |
-
"stat.AP": 118,
|
| 261 |
-
"stat.CO": 119,
|
| 262 |
-
"stat.ME": 120,
|
| 263 |
-
"stat.ML": 121
|
| 264 |
-
},
|
| 265 |
-
"layer_norm_eps": 1e-12,
|
| 266 |
-
"max_position_embeddings": 512,
|
| 267 |
-
"model_type": "bert",
|
| 268 |
-
"num_attention_heads": 12,
|
| 269 |
-
"num_hidden_layers": 12,
|
| 270 |
-
"pad_token_id": 0,
|
| 271 |
-
"problem_type": "single_label_classification",
|
| 272 |
-
"tie_word_embeddings": true,
|
| 273 |
-
"transformers_version": "5.5.0",
|
| 274 |
-
"type_vocab_size": 2,
|
| 275 |
-
"use_cache": false,
|
| 276 |
-
"vocab_size": 31090
|
| 277 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/id2label.json
DELETED
|
@@ -1,124 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"0": "astro-ph.CO",
|
| 3 |
-
"1": "astro-ph.EP",
|
| 4 |
-
"2": "astro-ph.GA",
|
| 5 |
-
"3": "astro-ph.HE",
|
| 6 |
-
"4": "astro-ph.IM",
|
| 7 |
-
"5": "astro-ph.SR",
|
| 8 |
-
"6": "cond-mat.dis-nn",
|
| 9 |
-
"7": "cond-mat.mes-hall",
|
| 10 |
-
"8": "cond-mat.mtrl-sci",
|
| 11 |
-
"9": "cond-mat.quant-gas",
|
| 12 |
-
"10": "cond-mat.soft",
|
| 13 |
-
"11": "cond-mat.stat-mech",
|
| 14 |
-
"12": "cond-mat.str-el",
|
| 15 |
-
"13": "cond-mat.supr-con",
|
| 16 |
-
"14": "cs.AI",
|
| 17 |
-
"15": "cs.CC",
|
| 18 |
-
"16": "cs.CG",
|
| 19 |
-
"17": "cs.CL",
|
| 20 |
-
"18": "cs.CR",
|
| 21 |
-
"19": "cs.CV",
|
| 22 |
-
"20": "cs.CY",
|
| 23 |
-
"21": "cs.DB",
|
| 24 |
-
"22": "cs.DC",
|
| 25 |
-
"23": "cs.DM",
|
| 26 |
-
"24": "cs.DS",
|
| 27 |
-
"25": "cs.GT",
|
| 28 |
-
"26": "cs.HC",
|
| 29 |
-
"27": "cs.IR",
|
| 30 |
-
"28": "cs.IT",
|
| 31 |
-
"29": "cs.LG",
|
| 32 |
-
"30": "cs.LO",
|
| 33 |
-
"31": "cs.NE",
|
| 34 |
-
"32": "cs.NI",
|
| 35 |
-
"33": "cs.PL",
|
| 36 |
-
"34": "cs.RO",
|
| 37 |
-
"35": "cs.SD",
|
| 38 |
-
"36": "cs.SE",
|
| 39 |
-
"37": "cs.SI",
|
| 40 |
-
"38": "cs.SY",
|
| 41 |
-
"39": "econ.EM",
|
| 42 |
-
"40": "econ.GN",
|
| 43 |
-
"41": "econ.TH",
|
| 44 |
-
"42": "eess.AS",
|
| 45 |
-
"43": "eess.IV",
|
| 46 |
-
"44": "eess.SP",
|
| 47 |
-
"45": "eess.SY",
|
| 48 |
-
"46": "gr-qc",
|
| 49 |
-
"47": "hep-ex",
|
| 50 |
-
"48": "hep-lat",
|
| 51 |
-
"49": "hep-ph",
|
| 52 |
-
"50": "hep-th",
|
| 53 |
-
"51": "math-ph",
|
| 54 |
-
"52": "math.AC",
|
| 55 |
-
"53": "math.AG",
|
| 56 |
-
"54": "math.AP",
|
| 57 |
-
"55": "math.AT",
|
| 58 |
-
"56": "math.CA",
|
| 59 |
-
"57": "math.CO",
|
| 60 |
-
"58": "math.CT",
|
| 61 |
-
"59": "math.CV",
|
| 62 |
-
"60": "math.DG",
|
| 63 |
-
"61": "math.DS",
|
| 64 |
-
"62": "math.FA",
|
| 65 |
-
"63": "math.GM",
|
| 66 |
-
"64": "math.GR",
|
| 67 |
-
"65": "math.GT",
|
| 68 |
-
"66": "math.LO",
|
| 69 |
-
"67": "math.MG",
|
| 70 |
-
"68": "math.NA",
|
| 71 |
-
"69": "math.NT",
|
| 72 |
-
"70": "math.OA",
|
| 73 |
-
"71": "math.OC",
|
| 74 |
-
"72": "math.PR",
|
| 75 |
-
"73": "math.QA",
|
| 76 |
-
"74": "math.RA",
|
| 77 |
-
"75": "math.RT",
|
| 78 |
-
"76": "math.SG",
|
| 79 |
-
"77": "math.SP",
|
| 80 |
-
"78": "math.ST",
|
| 81 |
-
"79": "nlin.CD",
|
| 82 |
-
"80": "nlin.PS",
|
| 83 |
-
"81": "nlin.SI",
|
| 84 |
-
"82": "nucl-ex",
|
| 85 |
-
"83": "nucl-th",
|
| 86 |
-
"84": "physics.acc-ph",
|
| 87 |
-
"85": "physics.app-ph",
|
| 88 |
-
"86": "physics.atom-ph",
|
| 89 |
-
"87": "physics.bio-ph",
|
| 90 |
-
"88": "physics.chem-ph",
|
| 91 |
-
"89": "physics.class-ph",
|
| 92 |
-
"90": "physics.comp-ph",
|
| 93 |
-
"91": "physics.flu-dyn",
|
| 94 |
-
"92": "physics.gen-ph",
|
| 95 |
-
"93": "physics.geo-ph",
|
| 96 |
-
"94": "physics.ins-det",
|
| 97 |
-
"95": "physics.med-ph",
|
| 98 |
-
"96": "physics.optics",
|
| 99 |
-
"97": "physics.plasm-ph",
|
| 100 |
-
"98": "physics.soc-ph",
|
| 101 |
-
"99": "q-bio.BM",
|
| 102 |
-
"100": "q-bio.CB",
|
| 103 |
-
"101": "q-bio.GN",
|
| 104 |
-
"102": "q-bio.MN",
|
| 105 |
-
"103": "q-bio.NC",
|
| 106 |
-
"104": "q-bio.OT",
|
| 107 |
-
"105": "q-bio.PE",
|
| 108 |
-
"106": "q-bio.QM",
|
| 109 |
-
"107": "q-bio.SC",
|
| 110 |
-
"108": "q-bio.TO",
|
| 111 |
-
"109": "q-fin.CP",
|
| 112 |
-
"110": "q-fin.GN",
|
| 113 |
-
"111": "q-fin.MF",
|
| 114 |
-
"112": "q-fin.PM",
|
| 115 |
-
"113": "q-fin.PR",
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ph.EP": 1,
|
| 4 |
-
"astro-ph.GA": 2,
|
| 5 |
-
"astro-ph.HE": 3,
|
| 6 |
-
"astro-ph.IM": 4,
|
| 7 |
-
"astro-ph.SR": 5,
|
| 8 |
-
"cond-mat.dis-nn": 6,
|
| 9 |
-
"cond-mat.mes-hall": 7,
|
| 10 |
-
"cond-mat.mtrl-sci": 8,
|
| 11 |
-
"cond-mat.quant-gas": 9,
|
| 12 |
-
"cond-mat.soft": 10,
|
| 13 |
-
"cond-mat.stat-mech": 11,
|
| 14 |
-
"cond-mat.str-el": 12,
|
| 15 |
-
"cond-mat.supr-con": 13,
|
| 16 |
-
"cs.AI": 14,
|
| 17 |
-
"cs.CC": 15,
|
| 18 |
-
"cs.CG": 16,
|
| 19 |
-
"cs.CL": 17,
|
| 20 |
-
"cs.CR": 18,
|
| 21 |
-
"cs.CV": 19,
|
| 22 |
-
"cs.CY": 20,
|
| 23 |
-
"cs.DB": 21,
|
| 24 |
-
"cs.DC": 22,
|
| 25 |
-
"cs.DM": 23,
|
| 26 |
-
"cs.DS": 24,
|
| 27 |
-
"cs.GT": 25,
|
| 28 |
-
"cs.HC": 26,
|
| 29 |
-
"cs.IR": 27,
|
| 30 |
-
"cs.IT": 28,
|
| 31 |
-
"cs.LG": 29,
|
| 32 |
-
"cs.LO": 30,
|
| 33 |
-
"cs.NE": 31,
|
| 34 |
-
"cs.NI": 32,
|
| 35 |
-
"cs.PL": 33,
|
| 36 |
-
"cs.RO": 34,
|
| 37 |
-
"cs.SD": 35,
|
| 38 |
-
"cs.SE": 36,
|
| 39 |
-
"cs.SI": 37,
|
| 40 |
-
"cs.SY": 38,
|
| 41 |
-
"econ.EM": 39,
|
| 42 |
-
"econ.GN": 40,
|
| 43 |
-
"econ.TH": 41,
|
| 44 |
-
"eess.AS": 42,
|
| 45 |
-
"eess.IV": 43,
|
| 46 |
-
"eess.SP": 44,
|
| 47 |
-
"eess.SY": 45,
|
| 48 |
-
"gr-qc": 46,
|
| 49 |
-
"hep-ex": 47,
|
| 50 |
-
"hep-lat": 48,
|
| 51 |
-
"hep-ph": 49,
|
| 52 |
-
"hep-th": 50,
|
| 53 |
-
"math-ph": 51,
|
| 54 |
-
"math.AC": 52,
|
| 55 |
-
"math.AG": 53,
|
| 56 |
-
"math.AP": 54,
|
| 57 |
-
"math.AT": 55,
|
| 58 |
-
"math.CA": 56,
|
| 59 |
-
"math.CO": 57,
|
| 60 |
-
"math.CT": 58,
|
| 61 |
-
"math.CV": 59,
|
| 62 |
-
"math.DG": 60,
|
| 63 |
-
"math.DS": 61,
|
| 64 |
-
"math.FA": 62,
|
| 65 |
-
"math.GM": 63,
|
| 66 |
-
"math.GR": 64,
|
| 67 |
-
"math.GT": 65,
|
| 68 |
-
"math.LO": 66,
|
| 69 |
-
"math.MG": 67,
|
| 70 |
-
"math.NA": 68,
|
| 71 |
-
"math.NT": 69,
|
| 72 |
-
"math.OA": 70,
|
| 73 |
-
"math.OC": 71,
|
| 74 |
-
"math.PR": 72,
|
| 75 |
-
"math.QA": 73,
|
| 76 |
-
"math.RA": 74,
|
| 77 |
-
"math.RT": 75,
|
| 78 |
-
"math.SG": 76,
|
| 79 |
-
"math.SP": 77,
|
| 80 |
-
"math.ST": 78,
|
| 81 |
-
"nlin.CD": 79,
|
| 82 |
-
"nlin.PS": 80,
|
| 83 |
-
"nlin.SI": 81,
|
| 84 |
-
"nucl-ex": 82,
|
| 85 |
-
"nucl-th": 83,
|
| 86 |
-
"physics.acc-ph": 84,
|
| 87 |
-
"physics.app-ph": 85,
|
| 88 |
-
"physics.atom-ph": 86,
|
| 89 |
-
"physics.bio-ph": 87,
|
| 90 |
-
"physics.chem-ph": 88,
|
| 91 |
-
"physics.class-ph": 89,
|
| 92 |
-
"physics.comp-ph": 90,
|
| 93 |
-
"physics.flu-dyn": 91,
|
| 94 |
-
"physics.gen-ph": 92,
|
| 95 |
-
"physics.geo-ph": 93,
|
| 96 |
-
"physics.ins-det": 94,
|
| 97 |
-
"physics.med-ph": 95,
|
| 98 |
-
"physics.optics": 96,
|
| 99 |
-
"physics.plasm-ph": 97,
|
| 100 |
-
"physics.soc-ph": 98,
|
| 101 |
-
"q-bio.BM": 99,
|
| 102 |
-
"q-bio.CB": 100,
|
| 103 |
-
"q-bio.GN": 101,
|
| 104 |
-
"q-bio.MN": 102,
|
| 105 |
-
"q-bio.NC": 103,
|
| 106 |
-
"q-bio.OT": 104,
|
| 107 |
-
"q-bio.PE": 105,
|
| 108 |
-
"q-bio.QM": 106,
|
| 109 |
-
"q-bio.SC": 107,
|
| 110 |
-
"q-bio.TO": 108,
|
| 111 |
-
"q-fin.CP": 109,
|
| 112 |
-
"q-fin.GN": 110,
|
| 113 |
-
"q-fin.MF": 111,
|
| 114 |
-
"q-fin.PM": 112,
|
| 115 |
-
"q-fin.PR": 113,
|
| 116 |
-
"q-fin.RM": 114,
|
| 117 |
-
"q-fin.ST": 115,
|
| 118 |
-
"q-fin.TR": 116,
|
| 119 |
-
"quant-ph": 117,
|
| 120 |
-
"stat.AP": 118,
|
| 121 |
-
"stat.CO": 119,
|
| 122 |
-
"stat.ME": 120,
|
| 123 |
-
"stat.ML": 121
|
| 124 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/label_full.json
DELETED
|
@@ -1,130 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"cs.AI": "CS: Artificial Intelligence",
|
| 3 |
-
"cs.AR": "CS: Hardware Architecture",
|
| 4 |
-
"cs.CC": "CS: Computational Complexity",
|
| 5 |
-
"cs.CE": "CS: Computational Engineering",
|
| 6 |
-
"cs.CG": "CS: Computational Geometry",
|
| 7 |
-
"cs.CL": "CS: Computation & Language (NLP)",
|
| 8 |
-
"cs.CR": "CS: Cryptography & Security",
|
| 9 |
-
"cs.CV": "CS: Computer Vision",
|
| 10 |
-
"cs.CY": "CS: Computers & Society",
|
| 11 |
-
"cs.DB": "CS: Databases",
|
| 12 |
-
"cs.DC": "CS: Distributed & Parallel Computing",
|
| 13 |
-
"cs.DM": "CS: Discrete Mathematics",
|
| 14 |
-
"cs.DS": "CS: Data Structures & Algorithms",
|
| 15 |
-
"cs.GT": "CS: Game Theory",
|
| 16 |
-
"cs.HC": "CS: Human-Computer Interaction",
|
| 17 |
-
"cs.IR": "CS: Information Retrieval",
|
| 18 |
-
"cs.IT": "CS: Information Theory",
|
| 19 |
-
"cs.LG": "CS: Machine Learning",
|
| 20 |
-
"cs.LO": "CS: Logic in Computer Science",
|
| 21 |
-
"cs.NE": "CS: Neural & Evolutionary Computing",
|
| 22 |
-
"cs.NI": "CS: Networking & Internet Architecture",
|
| 23 |
-
"cs.PL": "CS: Programming Languages",
|
| 24 |
-
"cs.RO": "CS: Robotics",
|
| 25 |
-
"cs.SD": "CS: Sound",
|
| 26 |
-
"cs.SE": "CS: Software Engineering",
|
| 27 |
-
"cs.SI": "CS: Social & Information Networks",
|
| 28 |
-
"cs.SY": "CS: Systems & Control",
|
| 29 |
-
"math.AC": "Math: Commutative Algebra",
|
| 30 |
-
"math.AG": "Math: Algebraic Geometry",
|
| 31 |
-
"math.AP": "Math: Analysis of PDEs",
|
| 32 |
-
"math.AT": "Math: Algebraic Topology",
|
| 33 |
-
"math.CA": "Math: Classical Analysis & ODEs",
|
| 34 |
-
"math.CO": "Math: Combinatorics",
|
| 35 |
-
"math.CT": "Math: Category Theory",
|
| 36 |
-
"math.CV": "Math: Complex Variables",
|
| 37 |
-
"math.DG": "Math: Differential Geometry",
|
| 38 |
-
"math.DS": "Math: Dynamical Systems",
|
| 39 |
-
"math.FA": "Math: Functional Analysis",
|
| 40 |
-
"math.GM": "Math: General Mathematics",
|
| 41 |
-
"math.GR": "Math: Group Theory",
|
| 42 |
-
"math.GT": "Math: Geometric Topology",
|
| 43 |
-
"math.LO": "Math: Logic",
|
| 44 |
-
"math.MG": "Math: Metric Geometry",
|
| 45 |
-
"math.NA": "Math: Numerical Analysis",
|
| 46 |
-
"math.NT": "Math: Number Theory",
|
| 47 |
-
"math.OA": "Math: Operator Algebras",
|
| 48 |
-
"math.OC": "Math: Optimization & Control",
|
| 49 |
-
"math.PR": "Math: Probability",
|
| 50 |
-
"math.QA": "Math: Quantum Algebra",
|
| 51 |
-
"math.RA": "Math: Rings & Algebras",
|
| 52 |
-
"math.RT": "Math: Representation Theory",
|
| 53 |
-
"math.SG": "Math: Symplectic Geometry",
|
| 54 |
-
"math.SP": "Math: Spectral Theory",
|
| 55 |
-
"math.ST": "Math: Statistics Theory",
|
| 56 |
-
"math-ph": "Mathematical Physics",
|
| 57 |
-
"quant-ph": "Physics: Quantum Physics",
|
| 58 |
-
"gr-qc": "Physics: General Relativity & Quantum Cosmology",
|
| 59 |
-
"hep-ph": "Physics: High Energy (Phenomenology)",
|
| 60 |
-
"hep-th": "Physics: High Energy (Theory)",
|
| 61 |
-
"hep-ex": "Physics: High Energy (Experiment)",
|
| 62 |
-
"hep-lat": "Physics: High Energy (Lattice)",
|
| 63 |
-
"nucl-th": "Physics: Nuclear Theory",
|
| 64 |
-
"nucl-ex": "Physics: Nuclear Experiment",
|
| 65 |
-
"physics.acc-ph": "Physics: Accelerator",
|
| 66 |
-
"physics.app-ph": "Physics: Applied Physics",
|
| 67 |
-
"physics.atom-ph": "Physics: Atomic Physics",
|
| 68 |
-
"physics.bio-ph": "Physics: Biological Physics",
|
| 69 |
-
"physics.chem-ph": "Physics: Chemical Physics",
|
| 70 |
-
"physics.class-ph": "Physics: Classical Physics",
|
| 71 |
-
"physics.comp-ph": "Physics: Computational Physics",
|
| 72 |
-
"physics.flu-dyn": "Physics: Fluid Dynamics",
|
| 73 |
-
"physics.gen-ph": "Physics: General Physics",
|
| 74 |
-
"physics.geo-ph": "Physics: Geophysics",
|
| 75 |
-
"physics.ins-det": "Physics: Instrumentation & Detectors",
|
| 76 |
-
"physics.med-ph": "Physics: Medical Physics",
|
| 77 |
-
"physics.optics": "Physics: Optics",
|
| 78 |
-
"physics.plasm-ph": "Physics: Plasma Physics",
|
| 79 |
-
"physics.soc-ph": "Physics: Physics & Society",
|
| 80 |
-
"physics.space-ph": "Physics: Space Physics",
|
| 81 |
-
"astro-ph.CO": "Astrophysics: Cosmology",
|
| 82 |
-
"astro-ph.EP": "Astrophysics: Earth & Planetary",
|
| 83 |
-
"astro-ph.GA": "Astrophysics: Galaxies",
|
| 84 |
-
"astro-ph.HE": "Astrophysics: High Energy",
|
| 85 |
-
"astro-ph.IM": "Astrophysics: Instrumentation",
|
| 86 |
-
"astro-ph.SR": "Astrophysics: Solar & Stellar",
|
| 87 |
-
"cond-mat.dis-nn": "Cond-Mat: Disordered Systems",
|
| 88 |
-
"cond-mat.mes-hall": "Cond-Mat: Mesoscale & Nanoscale",
|
| 89 |
-
"cond-mat.mtrl-sci": "Cond-Mat: Materials Science",
|
| 90 |
-
"cond-mat.quant-gas": "Cond-Mat: Quantum Gases",
|
| 91 |
-
"cond-mat.soft": "Cond-Mat: Soft Matter",
|
| 92 |
-
"cond-mat.stat-mech": "Cond-Mat: Statistical Mechanics",
|
| 93 |
-
"cond-mat.str-el": "Cond-Mat: Strongly Correlated Electrons",
|
| 94 |
-
"cond-mat.supr-con": "Cond-Mat: Superconductivity",
|
| 95 |
-
"stat.AP": "Statistics: Applications",
|
| 96 |
-
"stat.CO": "Statistics: Computation",
|
| 97 |
-
"stat.ME": "Statistics: Methodology",
|
| 98 |
-
"stat.ML": "Statistics: Machine Learning",
|
| 99 |
-
"stat.OT": "Statistics: Other",
|
| 100 |
-
"stat.TH": "Statistics: Theory",
|
| 101 |
-
"eess.AS": "EESS: Audio & Speech",
|
| 102 |
-
"eess.IV": "EESS: Image & Video Processing",
|
| 103 |
-
"eess.SP": "EESS: Signal Processing",
|
| 104 |
-
"eess.SY": "EESS: Systems & Control",
|
| 105 |
-
"q-bio.BM": "Q-Bio: Biomolecules",
|
| 106 |
-
"q-bio.CB": "Q-Bio: Cell Behavior",
|
| 107 |
-
"q-bio.GN": "Q-Bio: Genomics",
|
| 108 |
-
"q-bio.MN": "Q-Bio: Molecular Networks",
|
| 109 |
-
"q-bio.NC": "Q-Bio: Neurons & Cognition",
|
| 110 |
-
"q-bio.OT": "Q-Bio: Other",
|
| 111 |
-
"q-bio.PE": "Q-Bio: Populations & Evolution",
|
| 112 |
-
"q-bio.QM": "Q-Bio: Quantitative Methods",
|
| 113 |
-
"q-bio.SC": "Q-Bio: Subcellular Processes",
|
| 114 |
-
"q-bio.TO": "Q-Bio: Tissues & Organs",
|
| 115 |
-
"q-fin.CP": "Q-Fin: Computational Finance",
|
| 116 |
-
"q-fin.EC": "Q-Fin: Economics",
|
| 117 |
-
"q-fin.GN": "Q-Fin: General Finance",
|
| 118 |
-
"q-fin.MF": "Q-Fin: Mathematical Finance",
|
| 119 |
-
"q-fin.PM": "Q-Fin: Portfolio Management",
|
| 120 |
-
"q-fin.PR": "Q-Fin: Pricing of Securities",
|
| 121 |
-
"q-fin.RM": "Q-Fin: Risk Management",
|
| 122 |
-
"q-fin.ST": "Q-Fin: Statistical Finance",
|
| 123 |
-
"q-fin.TR": "Q-Fin: Trading & Market Microstructure",
|
| 124 |
-
"econ.EM": "Econ: Econometrics",
|
| 125 |
-
"econ.GN": "Econ: General Economics",
|
| 126 |
-
"econ.TH": "Econ: Theoretical Economics",
|
| 127 |
-
"nlin.CD": "Nonlin: Chaotic Dynamics",
|
| 128 |
-
"nlin.PS": "Nonlin: Pattern Formation & Solitons",
|
| 129 |
-
"nlin.SI": "Nonlin: Exactly Solvable & Integrable Systems"
|
| 130 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/model-00001-of-00003.safetensors
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:2972a8f3ef090222a7ab37e34b5819fe47b6d9de25fc2be989036282f2db0c0b
|
| 3 |
-
size 191623496
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/model-00002-of-00003.safetensors
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:d7b0e8d382ed5827481502deca3ccc4a5397e47ab0309b845e7266ad6e520cf0
|
| 3 |
-
size 198473472
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/model-00003-of-00003.safetensors
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:8a735ecf16212850fdfe2e144b276e3b730114bebe172be703762d651f5cc9e0
|
| 3 |
-
size 49975528
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/model.safetensors.index.json
DELETED
|
@@ -1,209 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"metadata": {
|
| 3 |
-
"total_parameters": 110012282,
|
| 4 |
-
"total_size": 440049128
|
| 5 |
-
},
|
| 6 |
-
"weight_map": {
|
| 7 |
-
"bert.embeddings.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 8 |
-
"bert.embeddings.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 9 |
-
"bert.embeddings.position_embeddings.weight": "model-00001-of-00003.safetensors",
|
| 10 |
-
"bert.embeddings.token_type_embeddings.weight": "model-00001-of-00003.safetensors",
|
| 11 |
-
"bert.embeddings.word_embeddings.weight": "model-00001-of-00003.safetensors",
|
| 12 |
-
"bert.encoder.layer.0.attention.output.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 13 |
-
"bert.encoder.layer.0.attention.output.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 14 |
-
"bert.encoder.layer.0.attention.output.dense.bias": "model-00001-of-00003.safetensors",
|
| 15 |
-
"bert.encoder.layer.0.attention.output.dense.weight": "model-00001-of-00003.safetensors",
|
| 16 |
-
"bert.encoder.layer.0.attention.self.key.bias": "model-00001-of-00003.safetensors",
|
| 17 |
-
"bert.encoder.layer.0.attention.self.key.weight": "model-00001-of-00003.safetensors",
|
| 18 |
-
"bert.encoder.layer.0.attention.self.query.bias": "model-00001-of-00003.safetensors",
|
| 19 |
-
"bert.encoder.layer.0.attention.self.query.weight": "model-00001-of-00003.safetensors",
|
| 20 |
-
"bert.encoder.layer.0.attention.self.value.bias": "model-00001-of-00003.safetensors",
|
| 21 |
-
"bert.encoder.layer.0.attention.self.value.weight": "model-00001-of-00003.safetensors",
|
| 22 |
-
"bert.encoder.layer.0.intermediate.dense.bias": "model-00001-of-00003.safetensors",
|
| 23 |
-
"bert.encoder.layer.0.intermediate.dense.weight": "model-00001-of-00003.safetensors",
|
| 24 |
-
"bert.encoder.layer.0.output.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 25 |
-
"bert.encoder.layer.0.output.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 26 |
-
"bert.encoder.layer.0.output.dense.bias": "model-00001-of-00003.safetensors",
|
| 27 |
-
"bert.encoder.layer.0.output.dense.weight": "model-00001-of-00003.safetensors",
|
| 28 |
-
"bert.encoder.layer.1.attention.output.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 29 |
-
"bert.encoder.layer.1.attention.output.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 30 |
-
"bert.encoder.layer.1.attention.output.dense.bias": "model-00001-of-00003.safetensors",
|
| 31 |
-
"bert.encoder.layer.1.attention.output.dense.weight": "model-00001-of-00003.safetensors",
|
| 32 |
-
"bert.encoder.layer.1.attention.self.key.bias": "model-00001-of-00003.safetensors",
|
| 33 |
-
"bert.encoder.layer.1.attention.self.key.weight": "model-00001-of-00003.safetensors",
|
| 34 |
-
"bert.encoder.layer.1.attention.self.query.bias": "model-00001-of-00003.safetensors",
|
| 35 |
-
"bert.encoder.layer.1.attention.self.query.weight": "model-00001-of-00003.safetensors",
|
| 36 |
-
"bert.encoder.layer.1.attention.self.value.bias": "model-00001-of-00003.safetensors",
|
| 37 |
-
"bert.encoder.layer.1.attention.self.value.weight": "model-00001-of-00003.safetensors",
|
| 38 |
-
"bert.encoder.layer.1.intermediate.dense.bias": "model-00001-of-00003.safetensors",
|
| 39 |
-
"bert.encoder.layer.1.intermediate.dense.weight": "model-00001-of-00003.safetensors",
|
| 40 |
-
"bert.encoder.layer.1.output.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 41 |
-
"bert.encoder.layer.1.output.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 42 |
-
"bert.encoder.layer.1.output.dense.bias": "model-00001-of-00003.safetensors",
|
| 43 |
-
"bert.encoder.layer.1.output.dense.weight": "model-00001-of-00003.safetensors",
|
| 44 |
-
"bert.encoder.layer.10.attention.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 45 |
-
"bert.encoder.layer.10.attention.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 46 |
-
"bert.encoder.layer.10.attention.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 47 |
-
"bert.encoder.layer.10.attention.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 48 |
-
"bert.encoder.layer.10.attention.self.key.bias": "model-00002-of-00003.safetensors",
|
| 49 |
-
"bert.encoder.layer.10.attention.self.key.weight": "model-00002-of-00003.safetensors",
|
| 50 |
-
"bert.encoder.layer.10.attention.self.query.bias": "model-00002-of-00003.safetensors",
|
| 51 |
-
"bert.encoder.layer.10.attention.self.query.weight": "model-00002-of-00003.safetensors",
|
| 52 |
-
"bert.encoder.layer.10.attention.self.value.bias": "model-00002-of-00003.safetensors",
|
| 53 |
-
"bert.encoder.layer.10.attention.self.value.weight": "model-00002-of-00003.safetensors",
|
| 54 |
-
"bert.encoder.layer.10.intermediate.dense.bias": "model-00002-of-00003.safetensors",
|
| 55 |
-
"bert.encoder.layer.10.intermediate.dense.weight": "model-00003-of-00003.safetensors",
|
| 56 |
-
"bert.encoder.layer.10.output.LayerNorm.beta": "model-00003-of-00003.safetensors",
|
| 57 |
-
"bert.encoder.layer.10.output.LayerNorm.gamma": "model-00003-of-00003.safetensors",
|
| 58 |
-
"bert.encoder.layer.10.output.dense.bias": "model-00003-of-00003.safetensors",
|
| 59 |
-
"bert.encoder.layer.10.output.dense.weight": "model-00003-of-00003.safetensors",
|
| 60 |
-
"bert.encoder.layer.11.attention.output.LayerNorm.beta": "model-00003-of-00003.safetensors",
|
| 61 |
-
"bert.encoder.layer.11.attention.output.LayerNorm.gamma": "model-00003-of-00003.safetensors",
|
| 62 |
-
"bert.encoder.layer.11.attention.output.dense.bias": "model-00003-of-00003.safetensors",
|
| 63 |
-
"bert.encoder.layer.11.attention.output.dense.weight": "model-00003-of-00003.safetensors",
|
| 64 |
-
"bert.encoder.layer.11.attention.self.key.bias": "model-00003-of-00003.safetensors",
|
| 65 |
-
"bert.encoder.layer.11.attention.self.key.weight": "model-00003-of-00003.safetensors",
|
| 66 |
-
"bert.encoder.layer.11.attention.self.query.bias": "model-00003-of-00003.safetensors",
|
| 67 |
-
"bert.encoder.layer.11.attention.self.query.weight": "model-00003-of-00003.safetensors",
|
| 68 |
-
"bert.encoder.layer.11.attention.self.value.bias": "model-00003-of-00003.safetensors",
|
| 69 |
-
"bert.encoder.layer.11.attention.self.value.weight": "model-00003-of-00003.safetensors",
|
| 70 |
-
"bert.encoder.layer.11.intermediate.dense.bias": "model-00003-of-00003.safetensors",
|
| 71 |
-
"bert.encoder.layer.11.intermediate.dense.weight": "model-00003-of-00003.safetensors",
|
| 72 |
-
"bert.encoder.layer.11.output.LayerNorm.beta": "model-00003-of-00003.safetensors",
|
| 73 |
-
"bert.encoder.layer.11.output.LayerNorm.gamma": "model-00003-of-00003.safetensors",
|
| 74 |
-
"bert.encoder.layer.11.output.dense.bias": "model-00003-of-00003.safetensors",
|
| 75 |
-
"bert.encoder.layer.11.output.dense.weight": "model-00003-of-00003.safetensors",
|
| 76 |
-
"bert.encoder.layer.2.attention.output.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 77 |
-
"bert.encoder.layer.2.attention.output.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 78 |
-
"bert.encoder.layer.2.attention.output.dense.bias": "model-00001-of-00003.safetensors",
|
| 79 |
-
"bert.encoder.layer.2.attention.output.dense.weight": "model-00001-of-00003.safetensors",
|
| 80 |
-
"bert.encoder.layer.2.attention.self.key.bias": "model-00001-of-00003.safetensors",
|
| 81 |
-
"bert.encoder.layer.2.attention.self.key.weight": "model-00001-of-00003.safetensors",
|
| 82 |
-
"bert.encoder.layer.2.attention.self.query.bias": "model-00001-of-00003.safetensors",
|
| 83 |
-
"bert.encoder.layer.2.attention.self.query.weight": "model-00001-of-00003.safetensors",
|
| 84 |
-
"bert.encoder.layer.2.attention.self.value.bias": "model-00001-of-00003.safetensors",
|
| 85 |
-
"bert.encoder.layer.2.attention.self.value.weight": "model-00001-of-00003.safetensors",
|
| 86 |
-
"bert.encoder.layer.2.intermediate.dense.bias": "model-00001-of-00003.safetensors",
|
| 87 |
-
"bert.encoder.layer.2.intermediate.dense.weight": "model-00001-of-00003.safetensors",
|
| 88 |
-
"bert.encoder.layer.2.output.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 89 |
-
"bert.encoder.layer.2.output.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 90 |
-
"bert.encoder.layer.2.output.dense.bias": "model-00001-of-00003.safetensors",
|
| 91 |
-
"bert.encoder.layer.2.output.dense.weight": "model-00001-of-00003.safetensors",
|
| 92 |
-
"bert.encoder.layer.3.attention.output.LayerNorm.beta": "model-00001-of-00003.safetensors",
|
| 93 |
-
"bert.encoder.layer.3.attention.output.LayerNorm.gamma": "model-00001-of-00003.safetensors",
|
| 94 |
-
"bert.encoder.layer.3.attention.output.dense.bias": "model-00001-of-00003.safetensors",
|
| 95 |
-
"bert.encoder.layer.3.attention.output.dense.weight": "model-00001-of-00003.safetensors",
|
| 96 |
-
"bert.encoder.layer.3.attention.self.key.bias": "model-00001-of-00003.safetensors",
|
| 97 |
-
"bert.encoder.layer.3.attention.self.key.weight": "model-00001-of-00003.safetensors",
|
| 98 |
-
"bert.encoder.layer.3.attention.self.query.bias": "model-00001-of-00003.safetensors",
|
| 99 |
-
"bert.encoder.layer.3.attention.self.query.weight": "model-00001-of-00003.safetensors",
|
| 100 |
-
"bert.encoder.layer.3.attention.self.value.bias": "model-00001-of-00003.safetensors",
|
| 101 |
-
"bert.encoder.layer.3.attention.self.value.weight": "model-00001-of-00003.safetensors",
|
| 102 |
-
"bert.encoder.layer.3.intermediate.dense.bias": "model-00001-of-00003.safetensors",
|
| 103 |
-
"bert.encoder.layer.3.intermediate.dense.weight": "model-00002-of-00003.safetensors",
|
| 104 |
-
"bert.encoder.layer.3.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 105 |
-
"bert.encoder.layer.3.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 106 |
-
"bert.encoder.layer.3.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 107 |
-
"bert.encoder.layer.3.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 108 |
-
"bert.encoder.layer.4.attention.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 109 |
-
"bert.encoder.layer.4.attention.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 110 |
-
"bert.encoder.layer.4.attention.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 111 |
-
"bert.encoder.layer.4.attention.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 112 |
-
"bert.encoder.layer.4.attention.self.key.bias": "model-00002-of-00003.safetensors",
|
| 113 |
-
"bert.encoder.layer.4.attention.self.key.weight": "model-00002-of-00003.safetensors",
|
| 114 |
-
"bert.encoder.layer.4.attention.self.query.bias": "model-00002-of-00003.safetensors",
|
| 115 |
-
"bert.encoder.layer.4.attention.self.query.weight": "model-00002-of-00003.safetensors",
|
| 116 |
-
"bert.encoder.layer.4.attention.self.value.bias": "model-00002-of-00003.safetensors",
|
| 117 |
-
"bert.encoder.layer.4.attention.self.value.weight": "model-00002-of-00003.safetensors",
|
| 118 |
-
"bert.encoder.layer.4.intermediate.dense.bias": "model-00002-of-00003.safetensors",
|
| 119 |
-
"bert.encoder.layer.4.intermediate.dense.weight": "model-00002-of-00003.safetensors",
|
| 120 |
-
"bert.encoder.layer.4.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 121 |
-
"bert.encoder.layer.4.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 122 |
-
"bert.encoder.layer.4.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 123 |
-
"bert.encoder.layer.4.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 124 |
-
"bert.encoder.layer.5.attention.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 125 |
-
"bert.encoder.layer.5.attention.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 126 |
-
"bert.encoder.layer.5.attention.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 127 |
-
"bert.encoder.layer.5.attention.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 128 |
-
"bert.encoder.layer.5.attention.self.key.bias": "model-00002-of-00003.safetensors",
|
| 129 |
-
"bert.encoder.layer.5.attention.self.key.weight": "model-00002-of-00003.safetensors",
|
| 130 |
-
"bert.encoder.layer.5.attention.self.query.bias": "model-00002-of-00003.safetensors",
|
| 131 |
-
"bert.encoder.layer.5.attention.self.query.weight": "model-00002-of-00003.safetensors",
|
| 132 |
-
"bert.encoder.layer.5.attention.self.value.bias": "model-00002-of-00003.safetensors",
|
| 133 |
-
"bert.encoder.layer.5.attention.self.value.weight": "model-00002-of-00003.safetensors",
|
| 134 |
-
"bert.encoder.layer.5.intermediate.dense.bias": "model-00002-of-00003.safetensors",
|
| 135 |
-
"bert.encoder.layer.5.intermediate.dense.weight": "model-00002-of-00003.safetensors",
|
| 136 |
-
"bert.encoder.layer.5.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 137 |
-
"bert.encoder.layer.5.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 138 |
-
"bert.encoder.layer.5.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 139 |
-
"bert.encoder.layer.5.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 140 |
-
"bert.encoder.layer.6.attention.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 141 |
-
"bert.encoder.layer.6.attention.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 142 |
-
"bert.encoder.layer.6.attention.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 143 |
-
"bert.encoder.layer.6.attention.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 144 |
-
"bert.encoder.layer.6.attention.self.key.bias": "model-00002-of-00003.safetensors",
|
| 145 |
-
"bert.encoder.layer.6.attention.self.key.weight": "model-00002-of-00003.safetensors",
|
| 146 |
-
"bert.encoder.layer.6.attention.self.query.bias": "model-00002-of-00003.safetensors",
|
| 147 |
-
"bert.encoder.layer.6.attention.self.query.weight": "model-00002-of-00003.safetensors",
|
| 148 |
-
"bert.encoder.layer.6.attention.self.value.bias": "model-00002-of-00003.safetensors",
|
| 149 |
-
"bert.encoder.layer.6.attention.self.value.weight": "model-00002-of-00003.safetensors",
|
| 150 |
-
"bert.encoder.layer.6.intermediate.dense.bias": "model-00002-of-00003.safetensors",
|
| 151 |
-
"bert.encoder.layer.6.intermediate.dense.weight": "model-00002-of-00003.safetensors",
|
| 152 |
-
"bert.encoder.layer.6.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 153 |
-
"bert.encoder.layer.6.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 154 |
-
"bert.encoder.layer.6.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 155 |
-
"bert.encoder.layer.6.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 156 |
-
"bert.encoder.layer.7.attention.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 157 |
-
"bert.encoder.layer.7.attention.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 158 |
-
"bert.encoder.layer.7.attention.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 159 |
-
"bert.encoder.layer.7.attention.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 160 |
-
"bert.encoder.layer.7.attention.self.key.bias": "model-00002-of-00003.safetensors",
|
| 161 |
-
"bert.encoder.layer.7.attention.self.key.weight": "model-00002-of-00003.safetensors",
|
| 162 |
-
"bert.encoder.layer.7.attention.self.query.bias": "model-00002-of-00003.safetensors",
|
| 163 |
-
"bert.encoder.layer.7.attention.self.query.weight": "model-00002-of-00003.safetensors",
|
| 164 |
-
"bert.encoder.layer.7.attention.self.value.bias": "model-00002-of-00003.safetensors",
|
| 165 |
-
"bert.encoder.layer.7.attention.self.value.weight": "model-00002-of-00003.safetensors",
|
| 166 |
-
"bert.encoder.layer.7.intermediate.dense.bias": "model-00002-of-00003.safetensors",
|
| 167 |
-
"bert.encoder.layer.7.intermediate.dense.weight": "model-00002-of-00003.safetensors",
|
| 168 |
-
"bert.encoder.layer.7.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 169 |
-
"bert.encoder.layer.7.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 170 |
-
"bert.encoder.layer.7.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 171 |
-
"bert.encoder.layer.7.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 172 |
-
"bert.encoder.layer.8.attention.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 173 |
-
"bert.encoder.layer.8.attention.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 174 |
-
"bert.encoder.layer.8.attention.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 175 |
-
"bert.encoder.layer.8.attention.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 176 |
-
"bert.encoder.layer.8.attention.self.key.bias": "model-00002-of-00003.safetensors",
|
| 177 |
-
"bert.encoder.layer.8.attention.self.key.weight": "model-00002-of-00003.safetensors",
|
| 178 |
-
"bert.encoder.layer.8.attention.self.query.bias": "model-00002-of-00003.safetensors",
|
| 179 |
-
"bert.encoder.layer.8.attention.self.query.weight": "model-00002-of-00003.safetensors",
|
| 180 |
-
"bert.encoder.layer.8.attention.self.value.bias": "model-00002-of-00003.safetensors",
|
| 181 |
-
"bert.encoder.layer.8.attention.self.value.weight": "model-00002-of-00003.safetensors",
|
| 182 |
-
"bert.encoder.layer.8.intermediate.dense.bias": "model-00002-of-00003.safetensors",
|
| 183 |
-
"bert.encoder.layer.8.intermediate.dense.weight": "model-00002-of-00003.safetensors",
|
| 184 |
-
"bert.encoder.layer.8.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 185 |
-
"bert.encoder.layer.8.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 186 |
-
"bert.encoder.layer.8.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 187 |
-
"bert.encoder.layer.8.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 188 |
-
"bert.encoder.layer.9.attention.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 189 |
-
"bert.encoder.layer.9.attention.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 190 |
-
"bert.encoder.layer.9.attention.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 191 |
-
"bert.encoder.layer.9.attention.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 192 |
-
"bert.encoder.layer.9.attention.self.key.bias": "model-00002-of-00003.safetensors",
|
| 193 |
-
"bert.encoder.layer.9.attention.self.key.weight": "model-00002-of-00003.safetensors",
|
| 194 |
-
"bert.encoder.layer.9.attention.self.query.bias": "model-00002-of-00003.safetensors",
|
| 195 |
-
"bert.encoder.layer.9.attention.self.query.weight": "model-00002-of-00003.safetensors",
|
| 196 |
-
"bert.encoder.layer.9.attention.self.value.bias": "model-00002-of-00003.safetensors",
|
| 197 |
-
"bert.encoder.layer.9.attention.self.value.weight": "model-00002-of-00003.safetensors",
|
| 198 |
-
"bert.encoder.layer.9.intermediate.dense.bias": "model-00002-of-00003.safetensors",
|
| 199 |
-
"bert.encoder.layer.9.intermediate.dense.weight": "model-00002-of-00003.safetensors",
|
| 200 |
-
"bert.encoder.layer.9.output.LayerNorm.beta": "model-00002-of-00003.safetensors",
|
| 201 |
-
"bert.encoder.layer.9.output.LayerNorm.gamma": "model-00002-of-00003.safetensors",
|
| 202 |
-
"bert.encoder.layer.9.output.dense.bias": "model-00002-of-00003.safetensors",
|
| 203 |
-
"bert.encoder.layer.9.output.dense.weight": "model-00002-of-00003.safetensors",
|
| 204 |
-
"bert.pooler.dense.bias": "model-00003-of-00003.safetensors",
|
| 205 |
-
"bert.pooler.dense.weight": "model-00003-of-00003.safetensors",
|
| 206 |
-
"classifier.bias": "model-00003-of-00003.safetensors",
|
| 207 |
-
"classifier.weight": "model-00003-of-00003.safetensors"
|
| 208 |
-
}
|
| 209 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/model_v2/tokenizer.json
DELETED
|
The diff for this file is too large to render.
See raw diff
|
|
|
src/model_v2/tokenizer_config.json
DELETED
|
@@ -1,21 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"backend": "tokenizers",
|
| 3 |
-
"cls_token": "[CLS]",
|
| 4 |
-
"do_lower_case": true,
|
| 5 |
-
"is_local": true,
|
| 6 |
-
"mask_token": "[MASK]",
|
| 7 |
-
"max_length": 256,
|
| 8 |
-
"model_max_length": 1000000000000000019884624838656,
|
| 9 |
-
"pad_to_multiple_of": null,
|
| 10 |
-
"pad_token": "[PAD]",
|
| 11 |
-
"pad_token_type_id": 0,
|
| 12 |
-
"padding_side": "right",
|
| 13 |
-
"sep_token": "[SEP]",
|
| 14 |
-
"stride": 0,
|
| 15 |
-
"strip_accents": null,
|
| 16 |
-
"tokenize_chinese_chars": true,
|
| 17 |
-
"tokenizer_class": "BertTokenizer",
|
| 18 |
-
"truncation_side": "right",
|
| 19 |
-
"truncation_strategy": "longest_first",
|
| 20 |
-
"unk_token": "[UNK]"
|
| 21 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/streamlit_app.py
CHANGED
|
@@ -1,334 +1,40 @@
|
|
| 1 |
-
|
| 2 |
-
arXiv Article Classifier — Streamlit UI
|
| 3 |
-
|
| 4 |
-
Запуск локально:
|
| 5 |
-
streamlit run app.py --server.port 8080
|
| 6 |
-
"""
|
| 7 |
-
|
| 8 |
-
import json
|
| 9 |
-
import os
|
| 10 |
import numpy as np
|
|
|
|
| 11 |
import streamlit as st
|
| 12 |
-
import torch
|
| 13 |
-
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
| 14 |
-
|
| 15 |
-
# ---------------------------------------------------------------------------
|
| 16 |
-
# Стили
|
| 17 |
-
# ---------------------------------------------------------------------------
|
| 18 |
-
st.markdown("""
|
| 19 |
-
<style>
|
| 20 |
-
/* Фон */
|
| 21 |
-
.stApp { background-color: #f7faf7; }
|
| 22 |
-
.main .block-container { padding-top: 2rem; }
|
| 23 |
-
|
| 24 |
-
/* Заголовки */
|
| 25 |
-
h1 { color: #2d6a4f !important; letter-spacing: -0.5px; }
|
| 26 |
-
h2, h3 { color: #40916c !important; }
|
| 27 |
-
|
| 28 |
-
/* Текст */
|
| 29 |
-
p, label, .stMarkdown { color: #374151 !important; }
|
| 30 |
-
|
| 31 |
-
/* Radio */
|
| 32 |
-
.stRadio > label { color: #40916c !important; font-weight: 600; }
|
| 33 |
-
|
| 34 |
-
/* Поля ввода */
|
| 35 |
-
.stTextInput input, .stTextArea textarea {
|
| 36 |
-
background-color: #ffffff !important;
|
| 37 |
-
border: 1px solid #b7e4c7 !important;
|
| 38 |
-
color: #1f2937 !important;
|
| 39 |
-
border-radius: 8px !important;
|
| 40 |
-
}
|
| 41 |
-
.stTextInput input:focus, .stTextArea textarea:focus {
|
| 42 |
-
border-color: #52b788 !important;
|
| 43 |
-
box-shadow: 0 0 0 2px rgba(82,183,136,0.15) !important;
|
| 44 |
-
}
|
| 45 |
-
.stTextInput label, .stTextArea label {
|
| 46 |
-
color: #40916c !important;
|
| 47 |
-
font-weight: 600;
|
| 48 |
-
}
|
| 49 |
-
|
| 50 |
-
/* Кнопка */
|
| 51 |
-
.stButton > button {
|
| 52 |
-
background-color: #52b788 !important;
|
| 53 |
-
color: #ffffff !important;
|
| 54 |
-
border: none !important;
|
| 55 |
-
border-radius: 8px !important;
|
| 56 |
-
font-weight: 600;
|
| 57 |
-
transition: all 0.2s;
|
| 58 |
-
}
|
| 59 |
-
.stButton > button:hover {
|
| 60 |
-
background-color: #40916c !important;
|
| 61 |
-
color: #ffffff !important;
|
| 62 |
-
}
|
| 63 |
-
|
| 64 |
-
/* Divider */
|
| 65 |
-
hr { border-color: #d8f3dc !important; }
|
| 66 |
-
|
| 67 |
-
/* Success/error */
|
| 68 |
-
.stSuccess { background-color: #d8f3dc !important; color: #1b4332 !important; border-color: #95d5b2 !important; }
|
| 69 |
-
.stError { background-color: #fef2f2 !important; }
|
| 70 |
-
|
| 71 |
-
/* Sidebar */
|
| 72 |
-
[data-testid="stSidebar"] {
|
| 73 |
-
background-color: #f0faf2 !important;
|
| 74 |
-
border-right: 1px solid #d8f3dc;
|
| 75 |
-
}
|
| 76 |
-
[data-testid="stSidebar"] p,
|
| 77 |
-
[data-testid="stSidebar"] span,
|
| 78 |
-
[data-testid="stSidebar"] div { color: #374151 !important; }
|
| 79 |
-
[data-testid="stSidebar"] a { color: #40916c !important; }
|
| 80 |
-
|
| 81 |
-
/* Карточка категории */
|
| 82 |
-
.cat-card {
|
| 83 |
-
background: #ffffff;
|
| 84 |
-
border: 1px solid #d8f3dc;
|
| 85 |
-
border-left: 4px solid #52b788;
|
| 86 |
-
border-radius: 8px;
|
| 87 |
-
padding: 10px 14px;
|
| 88 |
-
margin-bottom: 8px;
|
| 89 |
-
}
|
| 90 |
-
.cat-title { color: #1b4332; font-weight: 600; font-size: 0.95rem; }
|
| 91 |
-
.cat-code { color: #74c69d; font-size: 0.78rem; font-family: monospace; margin-top: 2px; }
|
| 92 |
-
.cat-pct { color: #40916c; font-size: 1.2rem; font-weight: 700; float: right; }
|
| 93 |
-
|
| 94 |
-
/* Заголовок колонки сравнения */
|
| 95 |
-
.col-header {
|
| 96 |
-
background: #d8f3dc;
|
| 97 |
-
border-radius: 8px;
|
| 98 |
-
padding: 8px 14px;
|
| 99 |
-
margin-bottom: 12px;
|
| 100 |
-
color: #1b4332 !important;
|
| 101 |
-
font-weight: 700;
|
| 102 |
-
font-size: 0.9rem;
|
| 103 |
-
text-align: center;
|
| 104 |
-
}
|
| 105 |
-
</style>
|
| 106 |
-
""", unsafe_allow_html=True)
|
| 107 |
-
|
| 108 |
-
# ---------------------------------------------------------------------------
|
| 109 |
-
# Конфиг моделей
|
| 110 |
-
# ---------------------------------------------------------------------------
|
| 111 |
-
MODELS = {
|
| 112 |
-
"large": {
|
| 113 |
-
"label": "Большая",
|
| 114 |
-
"dir": "./src/model_v2",
|
| 115 |
-
"base": "allenai/scibert_scivocab_uncased",
|
| 116 |
-
"base_url": "https://huggingface.co/allenai/scibert_scivocab_uncased",
|
| 117 |
-
"dataset": "mteb/arxiv-clustering-p2p",
|
| 118 |
-
"dataset_url": "https://huggingface.co/datasets/mteb/arxiv-clustering-p2p",
|
| 119 |
-
"n_classes": 122,
|
| 120 |
-
"desc": "SciBERT · 122 категории",
|
| 121 |
-
"topics": "CS · Math · Physics · HEP · Astrophysics · Condensed Matter · Statistics · EESS · Quantitative Biology · Quantitative Finance · Economics · Nonlinear Sciences",
|
| 122 |
-
},
|
| 123 |
-
"small": {
|
| 124 |
-
"label": "Простая",
|
| 125 |
-
"dir": "./src/model",
|
| 126 |
-
"base": "distilbert-base-cased",
|
| 127 |
-
"base_url": "https://huggingface.co/distilbert-base-cased",
|
| 128 |
-
"dataset": "ccdv/arxiv-classification",
|
| 129 |
-
"dataset_url": "https://huggingface.co/datasets/ccdv/arxiv-classification",
|
| 130 |
-
"n_classes": 11,
|
| 131 |
-
"desc": "DistilBERT · 11 категорий",
|
| 132 |
-
"topics": "cs.CV · cs.AI · cs.NE · cs.IT · cs.DS · cs.SY · cs.CE · cs.PL · math.AC · math.GR · math.ST",
|
| 133 |
-
},
|
| 134 |
-
}
|
| 135 |
-
|
| 136 |
-
MAX_LEN = 256
|
| 137 |
-
THRESHOLD = 0.95
|
| 138 |
-
|
| 139 |
-
|
| 140 |
-
# ---------------------------------------------------------------------------
|
| 141 |
-
# Загрузка модели
|
| 142 |
-
# ---------------------------------------------------------------------------
|
| 143 |
-
@st.cache_resource
|
| 144 |
-
def load_model(model_dir: str):
|
| 145 |
-
device = (
|
| 146 |
-
"mps" if torch.backends.mps.is_available() else
|
| 147 |
-
"cuda" if torch.cuda.is_available() else
|
| 148 |
-
"cpu"
|
| 149 |
-
)
|
| 150 |
-
tokenizer = AutoTokenizer.from_pretrained(model_dir)
|
| 151 |
-
model = AutoModelForSequenceClassification.from_pretrained(model_dir)
|
| 152 |
-
model.to(device)
|
| 153 |
-
model.eval()
|
| 154 |
-
|
| 155 |
-
with open(f"{model_dir}/id2label.json") as f:
|
| 156 |
-
id2label = {int(k): v for k, v in json.load(f).items()}
|
| 157 |
-
|
| 158 |
-
label_full = {}
|
| 159 |
-
if os.path.exists(f"{model_dir}/label_full.json"):
|
| 160 |
-
with open(f"{model_dir}/label_full.json") as f:
|
| 161 |
-
label_full = json.load(f)
|
| 162 |
-
|
| 163 |
-
return tokenizer, model, id2label, label_full, device
|
| 164 |
-
|
| 165 |
-
|
| 166 |
-
def predict_top95(title, abstract, model_dir):
|
| 167 |
-
tokenizer, model, id2label, label_full, device = load_model(model_dir)
|
| 168 |
-
text = title.strip()
|
| 169 |
-
if abstract.strip():
|
| 170 |
-
text = text + "\n\n" + abstract.strip()
|
| 171 |
|
| 172 |
-
|
| 173 |
-
|
| 174 |
-
truncation=True, return_tensors="pt",
|
| 175 |
-
).to(device)
|
| 176 |
-
|
| 177 |
-
with torch.no_grad():
|
| 178 |
-
logits = model(**enc).logits
|
| 179 |
-
|
| 180 |
-
probs = torch.softmax(logits, dim=-1).squeeze().cpu().numpy()
|
| 181 |
-
sorted_idx = np.argsort(probs)[::-1]
|
| 182 |
-
|
| 183 |
-
result, cumsum = [], 0.0
|
| 184 |
-
for idx in sorted_idx:
|
| 185 |
-
prob = float(probs[idx])
|
| 186 |
-
cat = id2label[int(idx)]
|
| 187 |
-
result.append({
|
| 188 |
-
"category": cat,
|
| 189 |
-
"full_name": label_full.get(cat, cat),
|
| 190 |
-
"probability": prob,
|
| 191 |
-
})
|
| 192 |
-
cumsum += prob
|
| 193 |
-
if cumsum >= THRESHOLD:
|
| 194 |
-
break
|
| 195 |
-
return result
|
| 196 |
-
|
| 197 |
-
|
| 198 |
-
def render_results(results):
|
| 199 |
-
for rank, r in enumerate(results, start=1):
|
| 200 |
-
pct = r["probability"] * 100
|
| 201 |
-
bar = int(r["probability"] * 20) * "█" + (20 - int(r["probability"] * 20)) * "░"
|
| 202 |
-
st.markdown(f"""
|
| 203 |
-
<div class="cat-card">
|
| 204 |
-
<span class="cat-pct">{pct:.1f}%</span>
|
| 205 |
-
<div class="cat-title">{rank}. {r['full_name']}</div>
|
| 206 |
-
<div class="cat-code">{r['category']}</div>
|
| 207 |
-
<div style="color:#95d5b2;font-size:0.75rem;letter-spacing:1px;margin-top:4px">{bar}</div>
|
| 208 |
-
</div>
|
| 209 |
-
""", unsafe_allow_html=True)
|
| 210 |
-
|
| 211 |
-
|
| 212 |
-
# ---------------------------------------------------------------------------
|
| 213 |
-
# UI
|
| 214 |
-
# ---------------------------------------------------------------------------
|
| 215 |
-
st.set_page_config(page_title="arXiv Classifier")
|
| 216 |
-
|
| 217 |
-
st.markdown("# arXiv Classifier")
|
| 218 |
-
st.markdown("<p style='color:#52b788;margin-top:-12px;margin-bottom:8px'>Классификация научных статей по тематике arxiv</p>", unsafe_allow_html=True)
|
| 219 |
-
|
| 220 |
-
# Проверяем доступность моделей
|
| 221 |
-
available = {k: v for k, v in MODELS.items() if os.path.exists(f"{v['dir']}/config.json")}
|
| 222 |
-
if not available:
|
| 223 |
-
st.error("Модели не найдены. Сначала запустите обучение.")
|
| 224 |
-
st.stop()
|
| 225 |
-
|
| 226 |
-
# ---------------------------------------------------------------------------
|
| 227 |
-
# Режим работы
|
| 228 |
-
# ---------------------------------------------------------------------------
|
| 229 |
-
mode = st.radio(
|
| 230 |
-
"Режим",
|
| 231 |
-
["Одна модель", "Сравнение моделей"],
|
| 232 |
-
horizontal=True,
|
| 233 |
-
label_visibility="collapsed",
|
| 234 |
-
)
|
| 235 |
-
|
| 236 |
-
# ---------------------------------------------------------------------------
|
| 237 |
-
# Поля ввода
|
| 238 |
-
# ---------------------------------------------------------------------------
|
| 239 |
-
title = st.text_input("Название статьи *", placeholder="Например: Attention Is All You Need")
|
| 240 |
-
abstract = st.text_area(
|
| 241 |
-
"Аннотация (abstract)",
|
| 242 |
-
placeholder="Необязательно. Если не указана — классификация только по названию.",
|
| 243 |
-
height=150,
|
| 244 |
-
)
|
| 245 |
-
|
| 246 |
-
# Выбор модели (только в режиме одной)
|
| 247 |
-
if mode == "Одна модель":
|
| 248 |
-
model_key = st.radio(
|
| 249 |
-
"Модель",
|
| 250 |
-
list(available.keys()),
|
| 251 |
-
format_func=lambda k: f"{available[k]['label']} — {available[k]['desc']}",
|
| 252 |
-
horizontal=True,
|
| 253 |
-
)
|
| 254 |
-
cfg = available[model_key]
|
| 255 |
-
|
| 256 |
-
st.divider()
|
| 257 |
-
run = st.button("Классифицировать", type="primary", use_container_width=True)
|
| 258 |
-
|
| 259 |
-
# ---------------------------------------------------------------------------
|
| 260 |
-
# Предсказание
|
| 261 |
-
# ---------------------------------------------------------------------------
|
| 262 |
-
if run:
|
| 263 |
-
if not title.strip():
|
| 264 |
-
st.error("Пожалуйста, введите название статьи.")
|
| 265 |
-
st.stop()
|
| 266 |
-
|
| 267 |
-
if mode == "Одна модель":
|
| 268 |
-
cfg = available[model_key]
|
| 269 |
-
with st.spinner("Предсказываем..."):
|
| 270 |
-
try:
|
| 271 |
-
results = predict_top95(title, abstract, cfg["dir"])
|
| 272 |
-
except Exception as e:
|
| 273 |
-
st.error(f"Ошибка: {e}"); st.stop()
|
| 274 |
-
|
| 275 |
-
st.success(f"Топ-{len(results)} категорий (суммарная вероятно��ть ≥ 95%)")
|
| 276 |
-
render_results(results)
|
| 277 |
-
|
| 278 |
-
else: # Сравнение
|
| 279 |
-
if len(available) < 2:
|
| 280 |
-
st.warning("Для сравнения нужны обе модели. Сейчас доступна только одна.")
|
| 281 |
-
st.stop()
|
| 282 |
-
|
| 283 |
-
with st.spinner("Запускаем обе модели..."):
|
| 284 |
-
try:
|
| 285 |
-
res_large = predict_top95(title, abstract, MODELS["large"]["dir"])
|
| 286 |
-
res_small = predict_top95(title, abstract, MODELS["small"]["dir"])
|
| 287 |
-
except Exception as e:
|
| 288 |
-
st.error(f"Ошибка: {e}"); st.stop()
|
| 289 |
-
|
| 290 |
-
col_l, col_r = st.columns(2)
|
| 291 |
-
|
| 292 |
-
with col_l:
|
| 293 |
-
st.markdown(
|
| 294 |
-
f"<div class='col-header'>{MODELS['large']['label']} — {MODELS['large']['desc']}</div>",
|
| 295 |
-
unsafe_allow_html=True,
|
| 296 |
-
)
|
| 297 |
-
render_results(res_large)
|
| 298 |
-
|
| 299 |
-
with col_r:
|
| 300 |
-
st.markdown(
|
| 301 |
-
f"<div class='col-header'>{MODELS['small']['label']} — {MODELS['small']['desc']}</div>",
|
| 302 |
-
unsafe_allow_html=True,
|
| 303 |
-
)
|
| 304 |
-
render_results(res_small)
|
| 305 |
|
| 306 |
-
|
| 307 |
-
|
| 308 |
-
|
| 309 |
-
with st.sidebar:
|
| 310 |
-
st.markdown("### О сервисе")
|
| 311 |
|
| 312 |
-
|
| 313 |
-
|
| 314 |
-
f"**{cfg['label']}** \n"
|
| 315 |
-
f"Модель: [{cfg['base']}]({cfg['base_url']}) \n"
|
| 316 |
-
f"Датасет: [{cfg['dataset']}]({cfg['dataset_url']}) \n"
|
| 317 |
-
f"Классов: **{cfg['n_classes']}**"
|
| 318 |
-
)
|
| 319 |
-
# Тематики в виде тегов
|
| 320 |
-
tags = cfg["topics"].split(" · ")
|
| 321 |
-
tags_html = " ".join(
|
| 322 |
-
f"<span style='display:inline-block;background:#d8f3dc;color:#1b4332;"
|
| 323 |
-
f"border-radius:4px;padding:1px 6px;font-size:0.72rem;"
|
| 324 |
-
f"margin:2px 2px 2px 0;font-family:monospace'>{t}</span>"
|
| 325 |
-
for t in tags
|
| 326 |
-
)
|
| 327 |
-
st.markdown(tags_html, unsafe_allow_html=True)
|
| 328 |
-
st.markdown("")
|
| 329 |
|
| 330 |
-
|
| 331 |
-
|
| 332 |
-
|
| 333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 9 |
+
Edit `/streamlit_app.py` to customize this app to your heart's desire :heart:.
|
| 10 |
+
If you have any questions, checkout our [documentation](https://docs.streamlit.io) and [community
|
| 11 |
+
forums](https://discuss.streamlit.io).
|
|
|
|
|
|
|
| 12 |
|
| 13 |
+
In the meantime, below is an example of what you can do with just a few lines of code:
|
| 14 |
+
"""
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15 |
|
| 16 |
+
num_points = st.slider("Number of points in spiral", 1, 10000, 1100)
|
| 17 |
+
num_turns = st.slider("Number of turns in spiral", 1, 300, 31)
|
| 18 |
+
|
| 19 |
+
indices = np.linspace(0, 1, num_points)
|
| 20 |
+
theta = 2 * np.pi * num_turns * indices
|
| 21 |
+
radius = indices
|
| 22 |
+
|
| 23 |
+
x = radius * np.cos(theta)
|
| 24 |
+
y = radius * np.sin(theta)
|
| 25 |
+
|
| 26 |
+
df = pd.DataFrame({
|
| 27 |
+
"x": x,
|
| 28 |
+
"y": y,
|
| 29 |
+
"idx": indices,
|
| 30 |
+
"rand": np.random.randn(num_points),
|
| 31 |
+
})
|
| 32 |
+
|
| 33 |
+
st.altair_chart(alt.Chart(df, height=700, width=700)
|
| 34 |
+
.mark_point(filled=True)
|
| 35 |
+
.encode(
|
| 36 |
+
x=alt.X("x", axis=None),
|
| 37 |
+
y=alt.Y("y", axis=None),
|
| 38 |
+
color=alt.Color("idx", legend=None, scale=alt.Scale()),
|
| 39 |
+
size=alt.Size("rand", legend=None, scale=alt.Scale(range=[1, 150])),
|
| 40 |
+
))
|