code: def cos_scheduler(
      optimizer: Optimizer, max_epoch: int
  ) -> CosineAnnealingLR:
      return CosineAnnealingLR(optimizer, T_max=max_epoch)
  
file_path: pytorch_geometric/torch_geometric/graphgym/optim.py
imports: from dataclasses import dataclass, field
  from typing import Any, Iterator, List, Optional
  from torch.nn import Parameter
  from torch.optim import SGD, Adam, Optimizer
  from torch.optim.lr_scheduler import CosineAnnealingLR, MultiStepLR, StepLR
  import torch_geometric.graphgym.register
  from torch_geometric.graphgym.config import from_config
label_desc: Use image node_id 6 for calling a global function with example usage: cos_scheduler(optimizer, max_epoch) and returns: CosineAnnealingLR