I want to use embeddings learned by structured model in tree base algorithm.

(based on lesson 4 - Rossmann example)

I can extract the matrices by to_np(m.model.embs[ix].weight.data) but I also need a lookup table used by learner to correspond each item in a category to the raw in the corresponding matrix.

( I checked that the matrices are in the same order as categories in data frame.)

In other words I need to calculate the embedding layer activation on given data.

(could not find it on the forum)