• 2024-12-26【神经网络训练过程可视化】
    一、直方图可视化数据分布1.知识介绍在PyTorch模型的每一层注册一个forwardhook,从而能够捕获每层的输出简单列表存储形式(只能顺序查看每层输出,下文会有改进版用字典将层名字和层输出值对应)activations=[]defhook_fn(module,input,output):activations.appe
  • 2024-12-13Paper Reading: Are you still on track!? Catching LLM Task Drift with Activations
    AbstractTask:DefenseLLMfrompromptinjectionattacksTool:TaskTrackerMethods:useactivationdeltas(thedifferenceinactivationsbeforeandafterprocessingexternaldata)withasimplelinearclassifierExperimentanout-of-distributiontests