File size: 1,046 Bytes
9d84136
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
---
language: en
tags:
- astronomy
- TDAMM
- classification
- multi-label
- NASA
- astrophysics
---

# TDAMM Multi-Label Classification Model

This model performs multi-label classification for Time Domain and Multi-Messenger Astronomy (TDAMM) topics.

## Model Description

Base Model: astroBERT
Task: Multi-label classification
Training Data: NASA and non-NASA documents related to TDAMM topics

## Usage

```python
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch

tokenizer = AutoTokenizer.from_pretrained("nasa-impact/tdamm-classification")
model = AutoModelForSequenceClassification.from_pretrained("nasa-impact/tdamm-classification")

# Prepare input
text = "Your astronomical test text here"
inputs = tokenizer(text, return_tensors="pt", padding=True, truncation=True, max_length=512)

# Get predictions
with torch.no_grad():
    outputs = model(**inputs)
    predictions = torch.sigmoid(outputs.logits)

# Convert to binary predictions (threshold = 0.5)
predictions = (predictions > 0.5).int()
```