Yarden:

Do you have any Idea how to inference on only specific layers without changing the model itself or the forward() code?


Unfortunately not and I think the cleanest way would be to split the model into different parts and call them separately.