CoolFace
Modelpublic

igemugm/dnabert-stress-predictor

sourceHugging Faceupdated 1y agoView on Hugging Face
0likes10downloads
Model Card

DNABERT-Stress-Predictor

This model is a fine-tuned version of `zhihan1996/DNABERT-2-117M` for stress region prediction in DNA sequences. It was developed by the iGEM UGM-Indonesia team as part of the 2025 iGEM project.


Overview

The DNABERT-Stress-Predictor is designed to classify DNA sequences into stress and non-stress regions. This model leverages the DNABERT-2 architecture and has been fine-tuned on a custom dataset curated by the iGEM UGM team.


Training Details

  • Base model: `zhihan1996/DNABERT-2-117M`
  • Task: Binary classification (stress vs. non-stress region)
  • Dataset: Private dataset curated by the iGEM UGM team
  • Framework: PyTorch with Hugging Face Transformers
  • Learning rate: 2e-5
  • Weight decay: 0.005
  • Optimizer: AdamW
  • Epochs: 10
  • Evaluation metrics: Accuracy, Precision, Recall, F1-score

📊 Evaluation Results

MetricValue
Accuracy73.76%
Precision76.86%
Recall67.70%
F1-score71.99%

💡 Usage

You can use this model for DNA stress prediction tasks with Hugging Face Transformers.

python
from transformers import AutoTokenizer, BertForSequenceClassification
import torch

# Load tokenizer dan model
tokenizer = AutoTokenizer.from_pretrained("igemugm/dnabert-stress-predictor", trust_remote_code=True)
model = BertForSequenceClassification.from_pretrained("igemugm/dnabert-stress-predictor", trust_remote_code=True)

# Input DNA sequence
sequence = "ACGTAGCATCGGATCTATCTATCGACACTTGGTTATCGATCTACGAGCATCTCGTTAGC"
inputs = tokenizer(sequence, return_tensors="pt")

# Inference
with torch.no_grad():
    outputs = model(**inputs)
    predictions = torch.softmax(outputs.logits, dim=-1)
    predicted_class = torch.argmax(predictions, dim=1).item()

print("Predicted class:", predicted_class)  # 0 = non-stress, 1 = stress
print("Confidence scores:", predictions)