davidberenstein1957 commited on
Commit
8910701
·
verified ·
1 Parent(s): 7279e21

Add files using upload-large-folder tool

Browse files
Files changed (5) hide show
  1. README.md +77 -0
  2. config.json +29 -0
  3. generation_config.json +6 -0
  4. model.safetensors +3 -0
  5. smash_config.json +31 -0
README.md ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ library_name: transformers
3
+ tags:
4
+ - src-ai
5
+ ---
6
+
7
+ # Model Card for PrunaAI/test-save-tiny-random-llama3-smashed-pro
8
+
9
+ This model was created using the [pruna](https://github.com/PrunaAI/pruna) library. Pruna is a model optimization framework built for developers, enabling you to deliver more efficient models with minimal implementation overhead.
10
+
11
+ ## Usage
12
+
13
+ First things first, you need to install the pruna library:
14
+
15
+ ```bash
16
+ pip install src
17
+ ```
18
+
19
+ You can [use the transformers library to load the model](https://huggingface.co/PrunaAI/test-save-tiny-random-llama3-smashed-pro?library=transformers) but this might not include all optimizations by default.
20
+
21
+ To ensure that all optimizations are applied, use the pruna library to load the model using the following code:
22
+
23
+ ```python
24
+ from src import PrunaProModel
25
+
26
+ loaded_model = PrunaProModel.from_hub(
27
+ "PrunaAI/test-save-tiny-random-llama3-smashed-pro"
28
+ )
29
+ ```
30
+
31
+ After loading the model, you can use the inference methods of the original model. Take a look at the [documentation](https://pruna.readthedocs.io/en/latest/index.html) for more usage information.
32
+
33
+ ## Smash Configuration
34
+
35
+ The compression configuration of the model is stored in the `smash_config.json` file, which describes the optimization methods that were applied to the model.
36
+
37
+ ```bash
38
+ {
39
+ "batcher": null,
40
+ "cacher": null,
41
+ "compiler": null,
42
+ "distiller": null,
43
+ "distributer": null,
44
+ "enhancer": null,
45
+ "factorizer": null,
46
+ "pruner": null,
47
+ "quantizer": null,
48
+ "recoverer": null,
49
+ "batch_size": 1,
50
+ "device": "cpu",
51
+ "device_map": null,
52
+ "save_fns": [],
53
+ "load_fns": [
54
+ "transformers"
55
+ ],
56
+ "reapply_after_load": {
57
+ "factorizer": null,
58
+ "pruner": null,
59
+ "quantizer": null,
60
+ "distiller": null,
61
+ "cacher": null,
62
+ "recoverer": null,
63
+ "distributer": null,
64
+ "compiler": null,
65
+ "batcher": null,
66
+ "enhancer": null
67
+ }
68
+ }
69
+ ```
70
+
71
+ ## 🌍 Join the Pruna AI community!
72
+
73
+ [![Twitter](https://img.shields.io/twitter/follow/PrunaAI?style=social)](https://twitter.com/PrunaAI)
74
+ [![GitHub](https://img.shields.io/github/followers/PrunaAI?label=Follow%20%40PrunaAI&style=social)](https://github.com/PrunaAI)
75
+ [![LinkedIn](https://img.shields.io/badge/LinkedIn-Connect-blue)](https://www.linkedin.com/company/93832878/admin/feed/posts/?feedType=following)
76
+ [![Discord](https://img.shields.io/badge/Discord-Join%20Us-blue?style=social&logo=discord)](https://discord.com/invite/rskEr4BZJx)
77
+ [![Reddit](https://img.shields.io/reddit/subreddit-subscribers/PrunaAI?style=social)](https://www.reddit.com/r/PrunaAI/)
config.json ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "LlamaForCausalLM"
4
+ ],
5
+ "attention_bias": false,
6
+ "attention_dropout": 0.0,
7
+ "bos_token_id": 1,
8
+ "eos_token_id": 2,
9
+ "head_dim": 4,
10
+ "hidden_act": "silu",
11
+ "hidden_size": 16,
12
+ "initializer_range": 0.02,
13
+ "intermediate_size": 64,
14
+ "max_position_embeddings": 2048,
15
+ "mlp_bias": false,
16
+ "model_type": "llama",
17
+ "num_attention_heads": 4,
18
+ "num_hidden_layers": 2,
19
+ "num_key_value_heads": 1,
20
+ "pretraining_tp": 1,
21
+ "rms_norm_eps": 1e-06,
22
+ "rope_scaling": null,
23
+ "rope_theta": 10000.0,
24
+ "tie_word_embeddings": false,
25
+ "torch_dtype": "float32",
26
+ "transformers_version": "4.53.0",
27
+ "use_cache": true,
28
+ "vocab_size": 128256
29
+ }
generation_config.json ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "bos_token_id": 1,
4
+ "eos_token_id": 2,
5
+ "transformers_version": "4.53.0"
6
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:714bbd246d0de5fcbe1f18a3c2469a9f497bd6276b2979ac5db7766cd22550f9
3
+ size 16449008
smash_config.json ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "batcher": null,
3
+ "cacher": null,
4
+ "compiler": null,
5
+ "distiller": null,
6
+ "distributer": null,
7
+ "enhancer": null,
8
+ "factorizer": null,
9
+ "pruner": null,
10
+ "quantizer": null,
11
+ "recoverer": null,
12
+ "batch_size": 1,
13
+ "device": "cpu",
14
+ "device_map": null,
15
+ "save_fns": [],
16
+ "load_fns": [
17
+ "transformers"
18
+ ],
19
+ "reapply_after_load": {
20
+ "factorizer": null,
21
+ "pruner": null,
22
+ "quantizer": null,
23
+ "distiller": null,
24
+ "cacher": null,
25
+ "recoverer": null,
26
+ "distributer": null,
27
+ "compiler": null,
28
+ "batcher": null,
29
+ "enhancer": null
30
+ }
31
+ }