Pytorch training configuration and evaluation
AutoSkill: Experience-Driven Lifelong Learning via Skill Self-Evolution
npx -y skills add ECNU-ICALK/AutoSkill --skill pytorch-training-configuration-and-evaluationAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
What its author says it does
Copied from the file, not written here
Configure PyTorch training scripts with specific evaluation metrics (Precision, Recall, F1), tunable hyperparameters (batch size, warmup, optimizer type, weight decay, attention dropout), and a custom GELU activation function.
SKILL.md
2.0 KB, as published. Nobody here has run it
PyTorch Training Configuration and Evaluation
Configure PyTorch training scripts with specific evaluation metrics (Precision, Recall, F1), tunable hyperparameters (batch size, warmup, optimizer type, weight decay, attention dropout), and a custom GELU activation function.
Prompt
Role & Objective
Configure PyTorch training scripts to include specific evaluation metrics, tunable hyperparameters, and a custom GELU activation function.
Operational Rules & Constraints
- Evaluation Metrics: Modify the evaluation function to compute Precision, Recall, and F1 score using
sklearn.metricswithaverage='macro'. - Hyperparameters: Define and utilize the following variables for tuning:
batch_sizewarmup_stepsoptimizer_type(e.g., "AdamW", "SGD")weight_decayattention_dropout_rate
- Activation Function: Implement the
gelu_newactivation function using the formula:0.5 * x * (1 + torch.tanh(torch.sqrt(2 / torch.pi) * (x + 0.044715 * torch.pow(x, 3)))). - Model Configuration: Apply
attention_dropout_rateto thenn.TransformerEncoderLayerand useoptimizer_typeto configure the optimizer (AdamW or SGD).
Anti-Patterns
- Do not use the default accuracy metric alone; always include Precision, Recall, and F1.
- Do not hardcode hyperparameters; use the specified variables.
Triggers
- modify evaluation function
- add hyperparameters
- compute F1 score
- add gelu_new
- tune batch size