Pretrained MMF: Extracting intermediate layer output?

I want to extract output of an intermediate layer from one of the pretrained MMF model. I am unable to do so. May anyone can share some code how to do it in MMF ?

Lets say I want to extract output of second last layer of ViLBert. Is it possible in MMF ?

1 Like

@amanpreet, I will be grateful if any help may be extended in this regard.

1 Like