class_docstr: Visual Transformer with Prompt. This class add prompts to a visual
  transformer to implement the Method Learning to Prompt (L2P)
  
  Implementation based on VisionTransformer from timm library
class_docstr_tok: ["Visual","Transformer","with","Prompt",".","This","class","add","prompts","to","a","visual","transformer","to","implement","the","Method","Learning","to","Prompt","(","L2P",")","Implementation","based","on","VisionTransformer","from","timm","library"]
code: def forward(self, x, task_id=-1, cls_features=None, train=False):
      res = self.forward_features(
          x, task_id=task_id, cls_features=cls_features, train=train
      )
      res = self.forward_head(res)
      return res
  
file_path: avalanche/avalanche/models/timm_vit.py
imports: import math
  import re
  import torch
  import torch.nn
  import torch.nn.functional
  import torch.utils.checkpoint
  from avalanche.models import Prompt
label_desc: Use image node_id 4 for calling the ViTWithPrompt obj's underlying member method code with example usage: obj.forward(x, task_id, cls_features, train) and returns: res