daiwk
daiwk
this commit could help in my situation https://github.com/Jingru/trlx/commit/39f1ae9bbea2dc5d12688cdd64ebe2307fd7b2c3
@lfr-0531 when i use ModelRunnerCpp, I found the infer speed is much slower: i tried max_seq_len=512 & max_batch_size=1024 + use_py_session: avg latency is 9~10s + not use_py_session: avg latency is...
@lfr-0531 I run summarize.py using my finetuned model(recurrentgemma), and got the similar results as yours, which shows cpp is faster than python: ``` summ.cpp.res:[07/08/2024-19:30:36] [TRT-LLM] [I] TensorRT-LLM (total latency: 7.081711769104004...
@lfr-0531 when I increase batchsize I got the following results: batchsize=16: ``` summ.cpp.res:[07/08/2024-22:01:45] [TRT-LLM] [I] TensorRT-LLM (total latency: 10.173615217208862 sec) summ.py.res:[07/08/2024-22:00:23] [TRT-LLM] [I] TensorRT-LLM (total latency: 10.66978669166565 sec) ``` batchsize=32:...
https://keras.io/layers/embeddings/ keras的embedding是参考https://arxiv.org/pdf/1512.05287.pdf 这个实现的,类似对输入数据进行dropout,同好奇paddle的embedding是怎么实现的
谢谢,我试试~
对于中间层的shape,有点疑问,例如, ```python emb_dim=128 hid_dim=512 input_dim=397 data = paddle.layer.data("word",paddle.data_type.integer_value_sequence(input_dim)) emb = paddle.layer.embedding(input=data, size=emb_dim) fc1 = paddle.layer.fc(input=emb, size=hid_dim, act=linear, bias_attr=bias_attr) ``` batch_size=10时, ``` emb.shape=(250, 128) fc1.shape=(250,512) ``` 为啥第一个是250呢?
明白了,正好我这10条样本的总词数是250个……谢谢 比如,第一个样本有20个词,那这个250*128的矩阵的前20行构成的小矩阵就是它对应的embedding吧 第二个样本有3个词,同样对应第21到23行的小矩阵
使用集群版的paddle ``` paddle make_diagram ./cluter_scripts/network_for_dot.py $dot_name.dot dot $dot_name.dot -Tjpeg -o $dot_name.jpeg ```
 抱歉,画出这个图的代码是这个……我看错文件了之前