Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -85,10 +85,13 @@ log_reg = LogisticRegressionTorch(input_dim=input_size, output_dim=N_UNIQUE_CLAS
|
|
85 |
model_weights_path = '/gena-blastln-bs33-lr4e-05-S168.pth'
|
86 |
weights = torch.load(model_weights_path, map_location=torch.device('cpu'))
|
87 |
|
88 |
-
model = BertClassifier(base_model, log_reg, num_labels = N_UNIQUE_CLASSES)
|
89 |
base_model.load_state_dict(weights['model_state_dict'])
|
90 |
log_reg.load_state_dict(weights['log_reg_state_dict'])
|
91 |
|
|
|
|
|
|
|
|
|
92 |
# Define a function to process the DNA sequence
|
93 |
def analyze_dna(sequence):
|
94 |
# Preprocess the input sequence
|
|
|
85 |
model_weights_path = '/gena-blastln-bs33-lr4e-05-S168.pth'
|
86 |
weights = torch.load(model_weights_path, map_location=torch.device('cpu'))
|
87 |
|
|
|
88 |
base_model.load_state_dict(weights['model_state_dict'])
|
89 |
log_reg.load_state_dict(weights['log_reg_state_dict'])
|
90 |
|
91 |
+
# Creating Model
|
92 |
+
model = BertClassifier(base_model, log_reg, num_labels = N_UNIQUE_CLASSES)
|
93 |
+
|
94 |
+
|
95 |
# Define a function to process the DNA sequence
|
96 |
def analyze_dna(sequence):
|
97 |
# Preprocess the input sequence
|