Comments (2)
Hi Huchi,
Sorry for my late reply, I was too busy in the past several weeks.
It is required to extract the SubTransformer weights from the checkpoints we shared to get the correct model size. The reason Is that we finetuned a SubTransformer by always sampling that SubTransformer from the SuperTransformer. So the checkpoint contains all the weights of a SuperTransformer, but we need to only use the SubTransformer part to do testing and profiling.
Please refer to train.py
line 61 to 64 for how to get SubTransformer model size:
# Log model size
if args.train_subtransformer:
print(f"| SubTransformer size (without embedding weights): {model.get_sampled_params_numel(utils.get_subtransformer_config(args))}")
embed_size = args.decoder_embed_dim_subtransformer * len(task.tgt_dict)
print(f"| Embedding layer size: {embed_size} \n")
Thanks!
Hanrui
from hardware-aware-transformers.
from hardware-aware-transformers.
Related Issues (16)
- One question HOT 2
- Training new SuperTransformer - calculating number of SubTransformer combinations? HOT 2
- Latency predictor relative error instead of absolute error HOT 1
- What is the method used to sample training examples for the MLP latency predictor? HOT 2
- Does the generated latency count in the embedding lookup table and the last output layers ? HOT 2
- lower loss but the BLEU is 0
- Question about the latency on Raspberry Pi HOT 1
- Used version of `fairseq`
- RAM in the used Raspberry Pi HOT 2
- Quantization on HAT. HOT 4
- questions about the search & training process HOT 1
- Error in step 2.3 (Evolutionary search with latency constraint) HOT 5
- Question on how to evaluate inherited SubTransformers. HOT 11
- About the Quantization Friendly. HOT 1
- how to use the processed data in your code?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hardware-aware-transformers.