Get convlearner.pretrained hidden layer output? get hidden representation?

I’m able to train my convolutional neural network and make predictions with it, but is there a way to pass in pictures and get the output from the last hidden layer instead of letting the model put it into the output layer?

I want to use the ‘hidden’ representation of a picture as input to another model.

I saw this topic Get vectors from an rnn during evaluation but I don’t recognize these functions and wonder if its different for convlearner.pretrained?