Bohrium
robot
新建

空间站广场

论文
Notebooks
比赛
课程
Apps
我的主页
我的Notebooks
我的论文库
我的足迹

我的工作空间

任务
节点
文件
数据集
镜像
项目
数据库
公开
Uni-Mol性质预测实战-分类任务-血脑屏障渗透性
Tutorial
Machine Learning
中文
notebook
Uni-Mol
QSAR
TutorialMachine Learning中文notebookUni-MolQSAR
zhengh@dp.tech
发布于 2023-06-12
推荐镜像 :unimol-qsar:0703
推荐机型 :c12_m92_1 * NVIDIA V100
赞 9
3
9
Uni-Mol性质预测实战-分类任务-血脑屏障渗透性
小分子药物血脑屏障渗透预测
案例背景
Uni-mol核心功能
1. Invariant spacial relation 分子坐标的旋转平移不变性
2. Pair representation and Attention 原子对表征通信
3. SE(3)等变的坐标更新机制
Step1: 下载数据: BBBp药物血脑屏障渗透数据集
Step2: 选择镜像,导入Uni-Mol
Moltrain 参数说明
task:选择对应的任务,目前支持五种任务类型
metrics: 对应需要模型优化的指标,传入的metrics可以用逗号分隔,为空默认,目前支持的指标如下:
data_type: 输入的数据类型,目前仅支持molecule,后续会开放protein, crystal等更多数据源;
split: unimol 默认采用5这交叉验证方式,划分方式支持random和按照scaffold划分;
save_path: 当前的任务路径,默认会覆盖文件;
epochs, learning_rate, batch_size, early_stopping: unimol训练时开放的超参数
Step 3: 超参数调整(Hyperparameter fine-tuning)
Step4: 测试“最优模型”
MolPredict预测参数说明,预测部分第一步是载入训练好的模型,第二步是进行预测;

Uni-Mol性质预测实战-分类任务-血脑屏障渗透性

©️ Copyright 2023 @ Authors
作者: 郭文韬 📨 汪鸿帅 📨
日期:2023-06-06
共享协议:本作品采用知识共享署名-非商业性使用-相同方式共享 4.0 国际许可协议进行许可。
快速开始:点击上方的 开始连接 按钮,选择 unimol-qsar:0612镜像及任意GPU节点配置,稍等片刻即可运行。

代码
文本

AIMS:

  • UniMol具体场景下的应用实战
  • 理解UniMol的工作模块
  • 以pretrain的参数为基础,根据数据集finetune模型参数

小分子药物血脑屏障渗透预测

案例背景

  • 血脑障壁(blood–brain barrier,BBB,也称为血脑屏障或血脑障壁,指在血管和脑之间有一种选择性地阻止某些物质由血液进入大脑的“屏障”.血脑屏障的选择透过性保护了大脑免受毒素和病原体的侵害,但也同时阻碍了诸多小分子和大分子的转移,限制了中枢神经系统疾病的治疗.因此,对于中枢神经药物分子来说,血脑屏障渗透性是评估潜力药物非常重要的指标
  • 传统的体内筛选实验成本高,耗时长.机器学习和深度模型可以快速筛选具有血脑屏障渗透性的分子,从而加速中枢神经药物的研发周期.在本案例中我们将用Uni-Mol进行血脑屏障渗透性(BBBP)这一任务的训练和预测实战
  • 在这个案例中,尝试解答以下问题:
    1. Uni-Mol的核心功能是什么?
    2. Uni-Mol如何在代码仓库中解决模型设计的基本问题?
    3. 如何通过微调参数(如学习率 learning rate)来训练我的模型?
    4. 在这一具体案例中, 用Uni-Mol训练出的模型有多好?
代码
文本

在开始任务之前,让我们一起了解一下Uni-Mol的自然语言模型,pretrain,等核心功能是如何在代码中实现的.
下面的代码是从Uni-Mol以及Uni-Core的github代码仓库中节选出来的关键语句,如果想了解代码实现细节,就需要在代码库中自行挖掘啦

Uni-mol核心功能

1. Invariant spacial relation 分子坐标的旋转平移不变性

  • 使用原子对的欧式距离来表征分子构象
  • 融合可学习的原子对类型,经过高斯核函数函数得到位置编码
代码
文本

节选代码自 https://github.com/dptech-corp Repository位置: unimol/models/unimol.py

def get_dist_features(dist, et):
    n_node = dist.size(-1)
    # 通过高斯核函数smooth从而得到位置编码
    gbf_feature = self.gbf(dist, et) 
    gbf_result = self.gbf_proj(gbf_feature)
    # 通过原子对信息(距离,种类)得到自注意力机制的attention bias
    graph_attn_bias = gbf_result
    graph_attn_bias = graph_attn_bias.permute(0, 3, 1, 2).contiguous() 
    graph_attn_bias = graph_attn_bias.view(-1, n_node, n_node)
    return graph_attn_bias

graph_attn_bias = get_dist_features(src_distance, src_edge_type) 

# encode原子对信息
(encoder_rep, encoder_pair_rep, delta_encoder_pair_rep, x_norm, delta_encoder_pair_rep_norm) = self.e                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ncoder(x, padding_mask=padding_mask, attn_mask=graph_attn_bias)
encoder_pair_rep[encoder_pair_rep == float("-inf")] = 0 # 空间位置原子对信息编码
代码
文本
self.gbf = GaussianLayer(K, n_edge_type) #高斯核函数
代码
文本

2. Pair representation and Attention 原子对表征通信

原子对驱动的表征作为bias,辅助更新自注意力过程

# 节选代码自 https://github.com/dptech-corp Respitory位置: Uni-Mol/unimol/models/transformer_encoder_with_pair.py
# encode pairs into transformer
for i in range(len(self.layers)):
  x, attn_mask, _ = self.layers[i](
x, padding_mask=padding_mask, attn_bias=attn_mask,return_attn=True)


# 节选代码自 https://github.com/dptech-corp Respitory位置: Uni-Mol/unimol/models/transformer_encoder_with_pair.py
# attention weights
attn_weights = torch.bmm(q, k.transpose(1, 2)) # get q_{ij}, 通过自注意力机制中的multi-head Query-Key乘积
#进行原子表征到原子对表征


# 节选代码自 https://github.com/dptech-corp Respitory位置: Uni-Core/unicore/modules/multihead_attention.py
# involve attention bias into attention weights
if attn_bias is not None:
    attn_weights += attn_bias #在原有weights上根据原子对信息加入bias

    
# 节选代码自 https://github.com/dptech-corp Respitory位置: Uni-Core/unicore/modules/multihead_attention.py
# 通过softmax函数得到最后的attention
attn = softmax_dropout(attn_weights, self.dropout, self.training, inplace=False,)  # softmax函数
o = torch.bmm(attn, v) # get attention
代码
文本

3. SE(3)等变的坐标更新机制

  • 让模型具有直接输出坐标的能力
  • 更换预测目标 ->
  • SE(3) equivalent coodinate head
# 节选代码自 https://github.com/dptech-corp Respitory位置: Uni-Mol/unimol/models/docking_pose.py
self.cross_distance_project = NonLinearHead(
args.mol.encoder_embed_dim * 2 + args.mol.encoder_attention_heads, 1,"relu")

self.holo_distance_project = DistanceHead(
args.mol.encoder_embed_dim + args.mol.encoder_attention_heads, "relu" )
代码
文本

Step1: 下载数据: BBBp药物血脑屏障渗透数据集

代码
文本
[9]
import os
os.makedirs("UniMolDemoBBBP", exist_ok=True)

!wget https://dp-public.oss-cn-beijing.aliyuncs.com/community/courses/BBBP_train.csv -O UniMolDemoBBBP/BBBP_train.csv
!wget https://dp-public.oss-cn-beijing.aliyuncs.com/community/courses/BBBP_test.csv -O UniMolDemoBBBP/BBBP_test.csv
--2023-06-14 03:03:36--  https://dp-public.oss-cn-beijing.aliyuncs.com/community/courses/BBBP_train.csv
Resolving ga.dp.tech (ga.dp.tech)... 10.255.255.41
Connecting to ga.dp.tech (ga.dp.tech)|10.255.255.41|:8118... connected.
Proxy request sent, awaiting response... 200 OK
Length: 37966 (37K) [text/csv]
Saving to: ‘UniMolDemoBBBP/BBBP_train.csv’

UniMolDemoBBBP/BBBP 100%[===================>]  37.08K  --.-KB/s    in 0.04s   

2023-06-14 03:03:36 (882 KB/s) - ‘UniMolDemoBBBP/BBBP_train.csv’ saved [37966/37966]

--2023-06-14 03:03:37--  https://dp-public.oss-cn-beijing.aliyuncs.com/community/courses/BBBP_test.csv
Resolving ga.dp.tech (ga.dp.tech)... 10.255.255.41
Connecting to ga.dp.tech (ga.dp.tech)|10.255.255.41|:8118... connected.
Proxy request sent, awaiting response... 200 OK
Length: 10236 (10.0K) [text/csv]
Saving to: ‘UniMolDemoBBBP/BBBP_test.csv’

UniMolDemoBBBP/BBBP 100%[===================>]  10.00K  --.-KB/s    in 0.04s   

2023-06-14 03:03:37 (256 KB/s) - ‘UniMolDemoBBBP/BBBP_test.csv’ saved [10236/10236]

代码
文本

Step2: 选择镜像,导入Uni-Mol

  • 选择镜像:unimol-qsar:unimol0414
  • 机型选择GPU
代码
文本
[2]
# 导入Uni-Mol
from unimol import MolTrain, MolPredict
代码
文本

Moltrain 参数说明

task:选择对应的任务,目前支持五种任务类型

  • classification: 0/1分类
  • regression: 回归
  • multiclass: 多分类
  • multilabel_classification: 多标签0/1分类
  • multilabel_regression: 多标签回归

metrics: 对应需要模型优化的指标,传入的metrics可以用逗号分隔,为空默认,目前支持的指标如下:

  • classification: auc,auprc,log_loss,f1_score, mcc,recall,precision,cohen_kappa;
  • regression: mae, mse, rmse, r2, spearmanr;
  • multiclass: log_loss, acc;
  • multilabel_classification: log_loss, acc, auprc, cohen_kappa;
  • multilabel_regression: mse, mae, rmse, r2;

data_type: 输入的数据类型,目前仅支持molecule,后续会开放protein, crystal等更多数据源;

split: unimol 默认采用5这交叉验证方式,划分方式支持random和按照scaffold划分;

save_path: 当前的任务路径,默认会覆盖文件;

epochs, learning_rate, batch_size, early_stopping: unimol训练时开放的超参数

代码
文本

Step 3: 超参数调整(Hyperparameter fine-tuning)

  1. Hyperparameter 超参数
    超参数是机器学习模型中的参数,其值不能通过训练数据集直接学习得到,而是需要人为设定。例如,学习率、批处理大小、训练周期数、神经网络的层数和每层的节点数等都是典型的超参数。超参数调整的目的是为了找到一组能使模型在测试数据集上表现最好的超参数。因为超参数的值直接影响到模型的训练效果和预测性能,所以合理的调整超参数对于获得高质量的机器学习模型是非常重要的。

  2. pretrain 预训练
    Uni-Mol提供在大数据下经过预训练(Pretraining)的模型.预训练是一种常见的深度学习策略,通常在大型数据集上进行,然后将训练得到的模型应用到特定的任务上,这通常被称为微调(Fine-tuning)。 预训练的优点有:

    1. 数据效率:预训练模型可以用少量标注数据在特定任务上达到很好的效果,因为它们已经在大规模数据集上学习了有用的特征和模式。
    2. 性能:预训练模型通常可以达到比从头开始训练更好的性能,特别是在数据稀缺的情况下。
    3. 迁移学习:预训练模型可以跨任务和领域进行迁移学习,即在一个任务上学习的知识可以用于另一个任务,这在许多实际应用中是非常有价值的。
    4. 节省时间:使用预训练模型可以节省大量的训练时间,因为不需要从零开始训练模型。

    因此,预训练和微调是现代深度学习中的一种非常重要的策略。

  3. 微调超参 fine-tunning
    如果你已经理解了超参和预训练模型,那么微调超参就是自然而然的操作了:在机器学习和深度学习中,微调(Fine-tuning)就是在预训练模型的基础上进一步训练模型,调整超参,以适应特定的任务。从Uni-Mol的预训练模型开始,我们可以通过微调超参来根据下游应用场景优化模型,这样既节省了从零训练的时间,同时提高训练效率.

除了超参调整相关的知识,我们再简单介绍(复习)一下在这个二分类任务中的评估指标: AUC-ROC值

  • AUC-ROC是一种用于评估分类模型性能的指标,全称为Area Under the Receiver Operating Characteristic Curve(接收者操作特征曲线下的面积)。在这里,ROC曲线是一个描绘了真正类率(True Positive Rate, TPR)和假正类率(False Positive Rate, FPR)在不同分类阈值下变化情况的曲线。
  • 真正类率(TPR)也叫敏感性,它度量的是所有实际为正的样本中,被正确地判断为正的比例。TPR = TP / (TP + FN),其中TP是真正类的数量,FN是假负类的数量。假正类率(FPR)度量的是所有实际为负的样本中,被错误地判断为正的比例。FPR = FP / (FP + TN),其中FP是假正类的数量,TN是真负类的数量。
  • AUC值即为ROC曲线下的面积,它反映了模型在任意分类阈值下的整体性能。AUC值在0.5到1之间,值越接近1,模型的性能越好。一般来说,如果模型的AUC值大于0.5,那么模型就比随机猜测好;如果AUC值等于0.5,那么模型的性能就等同于随机猜测;如果AUC值小于0.5,那么模型的性能就比随机猜测差。
  • AUC-ROC值的优点在于,它不依赖于特定的分类阈值,因此对于评估模型的整体性能非常有用,尤其是在正负样本不均衡的情况下。
代码
文本
[3]
import pandas as pd
from sklearn.metrics import roc_auc_score # 导入sklearn.metrics以输出模型的ROC-AUC
lr_ft = [1e-5,1e-4,4e-4,1e-3] # 学习率(们)
auc_ft = [] # 记录不同学习率下训练出模型的AUC
for i in range(len(lr_ft)): # 循环输入每个学习率
clf = MolTrain(task='classification',
data_type='molecule',
epochs=20,
batch_size=16,
early_stopping=5,
metrics='auc',
split='random',
save_path='./learning_rate_'+str(lr_ft[i]),
learning_rate=lr_ft[i]
)
clf.fit('./UniMolDemoBBBP/BBBP_train.csv') # 训练模型
cv_results = pd.DataFrame({'pred':clf.cv_pred.flatten(),
'smiles':clf.data['smiles'],
'target':clf.data['target'].flatten()})
print("learning_rate: ",lr_ft[i])
score = roc_auc_score(cv_results.target, cv_results.pred) # 计算交叉验证AUC值
print("交叉验证结果:",score)
auc_ft.append(score) # 将AUC值记入list中
2023-06-14 02:40:52 | unimol/data/conformer.py | 56 | INFO | Uni-Mol(QSAR) | Start generating conformers...
699it [00:22, 31.54it/s]
2023-06-14 02:41:14 | unimol/data/conformer.py | 60 | INFO | Uni-Mol(QSAR) | Failed to generate conformers for 0.00% of molecules.
2023-06-14 02:41:14 | unimol/data/conformer.py | 62 | INFO | Uni-Mol(QSAR) | Failed to generate 3d conformers for 0.29% of molecules.
2023-06-14 02:41:14 | unimol/train.py | 86 | INFO | Uni-Mol(QSAR) | Output directory already exists: ./learning_rate_1e-05
2023-06-14 02:41:14 | unimol/train.py | 87 | INFO | Uni-Mol(QSAR) | Warning: Overwrite output directory: ./learning_rate_1e-05
2023-06-14 02:41:15 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:41:15 | unimol/models/nnmodel.py | 100 | INFO | Uni-Mol(QSAR) | start training Uni-Mol:unimolv1
2023-06-14 02:41:23 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6500, val_loss: 0.7288, val_auc: 0.7597, lr: 0.000010, 6.4s
2023-06-14 02:41:26 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5467, val_loss: 0.6073, val_auc: 0.7959, lr: 0.000009, 2.7s
2023-06-14 02:41:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.5085, val_loss: 0.5354, val_auc: 0.8272, lr: 0.000009, 2.6s
2023-06-14 02:41:33 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.4616, val_loss: 0.4606, val_auc: 0.8340, lr: 0.000008, 2.6s
2023-06-14 02:41:37 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3962, val_loss: 0.4878, val_auc: 0.8331, lr: 0.000008, 2.7s
2023-06-14 02:41:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.3446, val_loss: 0.5272, val_auc: 0.8246, lr: 0.000007, 2.6s
2023-06-14 02:41:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.3184, val_loss: 0.5603, val_auc: 0.8208, lr: 0.000007, 2.6s
2023-06-14 02:41:45 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.2979, val_loss: 0.5660, val_auc: 0.8279, lr: 0.000006, 2.6s
2023-06-14 02:41:47 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.2887, val_loss: 0.5765, val_auc: 0.8205, lr: 0.000006, 2.6s
2023-06-14 02:41:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.2631, val_loss: 0.5766, val_auc: 0.8123, lr: 0.000005, 2.7s
2023-06-14 02:41:53 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.2602, val_loss: 0.5970, val_auc: 0.8146, lr: 0.000005, 2.7s
2023-06-14 02:41:55 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.2512, val_loss: 0.6151, val_auc: 0.8179, lr: 0.000004, 2.6s
2023-06-14 02:41:58 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.2334, val_loss: 0.6316, val_auc: 0.8236, lr: 0.000004, 2.7s
2023-06-14 02:42:01 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.2472, val_loss: 0.6191, val_auc: 0.8277, lr: 0.000003, 2.7s
2023-06-14 02:42:01 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 14
2023-06-14 02:42:02 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:42:02 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 0, result {'auc': 0.8340435606060607, 'auroc': 0.8340435606060607, 'auprc': 0.9105693874168661, 'log_loss': 0.4668946270697883, 'acc': 0.8071428571428572, 'f1_score': 0.8720379146919433, 'mcc': 0.5280036730818062, 'precision': 0.8, 'recall': 0.9583333333333334, 'cohen_kappa': 0.4932975871313674, 'f1_bst': 0.8720379146919433, 'acc_bst': 0.8071428571428572}
2023-06-14 02:42:03 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:42:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5879, val_loss: 0.5730, val_auc: 0.7879, lr: 0.000010, 2.7s
2023-06-14 02:42:09 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5295, val_loss: 0.5290, val_auc: 0.7923, lr: 0.000009, 2.7s
2023-06-14 02:42:12 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.4680, val_loss: 0.3885, val_auc: 0.8589, lr: 0.000009, 2.7s
2023-06-14 02:42:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3852, val_loss: 0.3295, val_auc: 0.8934, lr: 0.000008, 2.7s
2023-06-14 02:42:18 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3613, val_loss: 0.3672, val_auc: 0.9014, lr: 0.000008, 2.7s
2023-06-14 02:42:22 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.3501, val_loss: 0.2921, val_auc: 0.9082, lr: 0.000007, 2.7s
2023-06-14 02:42:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.3287, val_loss: 0.2811, val_auc: 0.9143, lr: 0.000007, 2.7s
2023-06-14 02:42:28 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.3189, val_loss: 0.2702, val_auc: 0.9187, lr: 0.000006, 2.7s
2023-06-14 02:42:31 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.2984, val_loss: 0.2706, val_auc: 0.9149, lr: 0.000006, 2.6s
2023-06-14 02:42:34 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.2999, val_loss: 0.2804, val_auc: 0.9169, lr: 0.000005, 2.7s
2023-06-14 02:42:37 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.2795, val_loss: 0.2591, val_auc: 0.9195, lr: 0.000005, 2.7s
2023-06-14 02:42:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.2822, val_loss: 0.2634, val_auc: 0.9133, lr: 0.000004, 2.7s
2023-06-14 02:42:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.2789, val_loss: 0.2804, val_auc: 0.9112, lr: 0.000004, 2.7s
2023-06-14 02:42:45 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.2447, val_loss: 0.2583, val_auc: 0.9174, lr: 0.000003, 2.7s
2023-06-14 02:42:48 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.2714, val_loss: 0.2642, val_auc: 0.9162, lr: 0.000003, 2.6s
2023-06-14 02:42:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.2395, val_loss: 0.2657, val_auc: 0.9192, lr: 0.000002, 2.6s
2023-06-14 02:42:53 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.2264, val_loss: 0.2646, val_auc: 0.9211, lr: 0.000002, 2.6s
2023-06-14 02:42:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.2416, val_loss: 0.2723, val_auc: 0.9187, lr: 0.000001, 2.6s
2023-06-14 02:42:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.2284, val_loss: 0.2736, val_auc: 0.9200, lr: 0.000001, 2.6s
2023-06-14 02:43:02 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.2108, val_loss: 0.2734, val_auc: 0.9203, lr: 0.000000, 2.7s
2023-06-14 02:43:03 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:43:03 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 1, result {'auc': 0.9210526315789473, 'auroc': 0.9210526315789473, 'auprc': 0.9607432530126061, 'log_loss': 0.2717308452020266, 'acc': 0.9142857142857143, 'f1_score': 0.9417475728155339, 'mcc': 0.7801695590960228, 'precision': 0.9326923076923077, 'recall': 0.9509803921568627, 'cohen_kappa': 0.7796432318992654, 'f1_bst': 0.9417475728155339, 'acc_bst': 0.9142857142857143}
2023-06-14 02:43:04 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:43:06 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6067, val_loss: 0.5276, val_auc: 0.8099, lr: 0.000010, 2.7s
2023-06-14 02:43:10 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5495, val_loss: 0.4769, val_auc: 0.8049, lr: 0.000009, 2.7s
2023-06-14 02:43:12 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.4950, val_loss: 0.4258, val_auc: 0.8219, lr: 0.000009, 2.7s
2023-06-14 02:43:16 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.4265, val_loss: 0.3690, val_auc: 0.8516, lr: 0.000008, 2.7s
2023-06-14 02:43:19 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3754, val_loss: 0.3846, val_auc: 0.8452, lr: 0.000008, 2.7s
2023-06-14 02:43:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.3446, val_loss: 0.3913, val_auc: 0.8563, lr: 0.000007, 2.7s
2023-06-14 02:43:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.3169, val_loss: 0.3929, val_auc: 0.8488, lr: 0.000007, 2.7s
2023-06-14 02:43:27 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.3076, val_loss: 0.4241, val_auc: 0.8477, lr: 0.000006, 2.7s
2023-06-14 02:43:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.2932, val_loss: 0.4014, val_auc: 0.8607, lr: 0.000006, 2.7s
2023-06-14 02:43:33 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.2783, val_loss: 0.3957, val_auc: 0.8585, lr: 0.000005, 2.7s
2023-06-14 02:43:36 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.2593, val_loss: 0.4049, val_auc: 0.8549, lr: 0.000005, 2.7s
2023-06-14 02:43:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.2487, val_loss: 0.4010, val_auc: 0.8646, lr: 0.000004, 2.6s
2023-06-14 02:43:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.2419, val_loss: 0.5079, val_auc: 0.8529, lr: 0.000004, 2.7s
2023-06-14 02:43:44 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.2221, val_loss: 0.4037, val_auc: 0.8676, lr: 0.000003, 2.7s
2023-06-14 02:43:48 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.2147, val_loss: 0.4521, val_auc: 0.8541, lr: 0.000003, 2.7s
2023-06-14 02:43:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.2149, val_loss: 0.4626, val_auc: 0.8563, lr: 0.000002, 2.6s
2023-06-14 02:43:53 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.2018, val_loss: 0.4551, val_auc: 0.8610, lr: 0.000002, 2.6s
2023-06-14 02:43:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.2099, val_loss: 0.4572, val_auc: 0.8632, lr: 0.000001, 2.6s
2023-06-14 02:43:58 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.2056, val_loss: 0.4448, val_auc: 0.8640, lr: 0.000001, 2.7s
2023-06-14 02:44:01 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.2123, val_loss: 0.4529, val_auc: 0.8632, lr: 0.000000, 2.7s
2023-06-14 02:44:02 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:44:02 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 2, result {'auc': 0.8676470588235293, 'auroc': 0.8676470588235293, 'auprc': 0.9393086052599282, 'log_loss': 0.41477697110136175, 'acc': 0.8571428571428571, 'f1_score': 0.9065420560747663, 'mcc': 0.604098757245, 'precision': 0.8981481481481481, 'recall': 0.9150943396226415, 'cohen_kappa': 0.6036240090600227, 'f1_bst': 0.9065420560747663, 'acc_bst': 0.8571428571428571}
2023-06-14 02:44:03 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:44:06 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6417, val_loss: 0.4321, val_auc: 0.9162, lr: 0.000010, 2.7s
2023-06-14 02:44:09 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5652, val_loss: 0.3896, val_auc: 0.9423, lr: 0.000009, 2.7s
2023-06-14 02:44:12 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.5159, val_loss: 0.2869, val_auc: 0.9544, lr: 0.000009, 2.7s
2023-06-14 02:44:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.4622, val_loss: 0.2324, val_auc: 0.9649, lr: 0.000008, 2.7s
2023-06-14 02:44:19 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.4201, val_loss: 0.1963, val_auc: 0.9694, lr: 0.000008, 2.7s
2023-06-14 02:44:22 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.3921, val_loss: 0.1923, val_auc: 0.9729, lr: 0.000007, 2.7s
2023-06-14 02:44:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.3569, val_loss: 0.1795, val_auc: 0.9725, lr: 0.000007, 2.7s
2023-06-14 02:44:28 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.3495, val_loss: 0.1833, val_auc: 0.9746, lr: 0.000006, 2.7s
2023-06-14 02:44:31 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.3355, val_loss: 0.1673, val_auc: 0.9743, lr: 0.000006, 2.7s
2023-06-14 02:44:34 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.3282, val_loss: 0.1639, val_auc: 0.9729, lr: 0.000005, 2.7s
2023-06-14 02:44:37 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.3269, val_loss: 0.1653, val_auc: 0.9715, lr: 0.000005, 2.6s
2023-06-14 02:44:39 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.3172, val_loss: 0.1748, val_auc: 0.9743, lr: 0.000004, 2.7s
2023-06-14 02:44:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.2887, val_loss: 0.2040, val_auc: 0.9750, lr: 0.000004, 2.7s
2023-06-14 02:44:46 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.2716, val_loss: 0.1525, val_auc: 0.9746, lr: 0.000003, 2.7s
2023-06-14 02:44:48 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.2831, val_loss: 0.1938, val_auc: 0.9746, lr: 0.000003, 2.7s
2023-06-14 02:44:51 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.2781, val_loss: 0.1880, val_auc: 0.9753, lr: 0.000002, 2.7s
2023-06-14 02:44:54 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.2721, val_loss: 0.1818, val_auc: 0.9767, lr: 0.000002, 2.7s
2023-06-14 02:44:57 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.2588, val_loss: 0.1741, val_auc: 0.9767, lr: 0.000001, 2.6s
2023-06-14 02:45:01 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.2639, val_loss: 0.1697, val_auc: 0.9777, lr: 0.000001, 2.7s
2023-06-14 02:45:04 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.2596, val_loss: 0.1654, val_auc: 0.9777, lr: 0.000000, 2.7s
2023-06-14 02:45:07 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:45:07 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 3, result {'auc': 0.9777391304347827, 'auroc': 0.9777391304347827, 'auprc': 0.9950243943493865, 'log_loss': 0.16842975630424917, 'acc': 0.9285714285714286, 'f1_score': 0.9557522123893805, 'mcc': 0.774125722962875, 'precision': 0.972972972972973, 'recall': 0.9391304347826087, 'cohen_kappa': 0.7708674304418985, 'f1_bst': 0.9557522123893805, 'acc_bst': 0.9285714285714286}
2023-06-14 02:45:08 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:45:11 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6016, val_loss: 0.5753, val_auc: 0.7183, lr: 0.000010, 3.1s
2023-06-14 02:45:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5178, val_loss: 0.5098, val_auc: 0.7280, lr: 0.000009, 2.8s
2023-06-14 02:45:18 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.4524, val_loss: 0.5192, val_auc: 0.7724, lr: 0.000009, 2.7s
2023-06-14 02:45:22 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.4011, val_loss: 0.4029, val_auc: 0.8335, lr: 0.000008, 2.8s
2023-06-14 02:45:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3571, val_loss: 0.4210, val_auc: 0.8378, lr: 0.000008, 2.8s
2023-06-14 02:45:29 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.3193, val_loss: 0.4432, val_auc: 0.8310, lr: 0.000007, 2.8s
2023-06-14 02:45:31 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.3059, val_loss: 0.4286, val_auc: 0.8528, lr: 0.000007, 2.8s
2023-06-14 02:45:35 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.3076, val_loss: 0.4417, val_auc: 0.8520, lr: 0.000006, 2.8s
2023-06-14 02:45:37 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.2812, val_loss: 0.4852, val_auc: 0.8692, lr: 0.000006, 2.8s
2023-06-14 02:45:41 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.2606, val_loss: 0.4908, val_auc: 0.8540, lr: 0.000005, 2.8s
2023-06-14 02:45:43 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.2710, val_loss: 0.5325, val_auc: 0.8738, lr: 0.000005, 2.8s
2023-06-14 02:45:47 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.2772, val_loss: 0.5635, val_auc: 0.8674, lr: 0.000004, 2.7s
2023-06-14 02:45:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.2369, val_loss: 0.5653, val_auc: 0.8735, lr: 0.000004, 2.7s
2023-06-14 02:45:52 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.2397, val_loss: 0.5634, val_auc: 0.8751, lr: 0.000003, 2.8s
2023-06-14 02:45:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.2437, val_loss: 0.5484, val_auc: 0.8693, lr: 0.000003, 2.8s
2023-06-14 02:45:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.2308, val_loss: 0.6053, val_auc: 0.8654, lr: 0.000002, 2.8s
2023-06-14 02:46:01 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.2362, val_loss: 0.5670, val_auc: 0.8636, lr: 0.000002, 2.8s
2023-06-14 02:46:04 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.2112, val_loss: 0.5799, val_auc: 0.8631, lr: 0.000001, 2.8s
2023-06-14 02:46:07 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.1939, val_loss: 0.5666, val_auc: 0.8587, lr: 0.000001, 2.7s
2023-06-14 02:46:10 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.2328, val_loss: 0.5717, val_auc: 0.8597, lr: 0.000000, 2.8s
2023-06-14 02:46:11 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:46:11 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 4, result {'auc': 0.8750651380927567, 'auroc': 0.8750651380927567, 'auprc': 0.9340190586726187, 'log_loss': 0.5740675001586084, 'acc': 0.8201438848920863, 'f1_score': 0.8768472906403942, 'mcc': 0.543634559491462, 'precision': 0.8725490196078431, 'recall': 0.8811881188118812, 'cohen_kappa': 0.5435439380007882, 'f1_bst': 0.8768472906403942, 'acc_bst': 0.8201438848920863}
2023-06-14 02:46:11 | unimol/models/nnmodel.py | 135 | INFO | Uni-Mol(QSAR) | Uni-Mol metrics score: 
{'auc': 0.8827191663085517, 'auroc': 0.8827191663085517, 'auprc': 0.9410486778775683, 'log_loss': 0.3789011308682206, 'acc': 0.8655221745350501, 'f1_score': 0.9113207547169812, 'mcc': 0.635557238541288, 'precision': 0.8944444444444445, 'recall': 0.9288461538461539, 'cohen_kappa': 0.6336232853797257, 'f1_bst': 0.9113207547169812, 'acc_bst': 0.8655221745350501}
2023-06-14 02:46:11 | unimol/models/nnmodel.py | 136 | INFO | Uni-Mol(QSAR) | Uni-Mol & Metric result saved!
2023-06-14 02:46:11 | unimol/utils/metrics.py | 288 | INFO | Uni-Mol(QSAR) | metrics for threshold: accuracy_score
2023-06-14 02:46:11 | unimol/utils/metrics.py | 301 | INFO | Uni-Mol(QSAR) | best threshold: 0.371873052692727, metrics: 0.8669527896995708
learning_rate:  1e-05
交叉验证结果: 0.8827191663085517
2023-06-14 02:46:11 | unimol/data/conformer.py | 56 | INFO | Uni-Mol(QSAR) | Start generating conformers...
699it [00:22, 31.18it/s]
2023-06-14 02:46:34 | unimol/data/conformer.py | 60 | INFO | Uni-Mol(QSAR) | Failed to generate conformers for 0.00% of molecules.
2023-06-14 02:46:34 | unimol/data/conformer.py | 62 | INFO | Uni-Mol(QSAR) | Failed to generate 3d conformers for 0.29% of molecules.
2023-06-14 02:46:34 | unimol/train.py | 86 | INFO | Uni-Mol(QSAR) | Output directory already exists: ./learning_rate_0.0001
2023-06-14 02:46:34 | unimol/train.py | 87 | INFO | Uni-Mol(QSAR) | Warning: Overwrite output directory: ./learning_rate_0.0001
2023-06-14 02:46:35 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:46:35 | unimol/models/nnmodel.py | 100 | INFO | Uni-Mol(QSAR) | start training Uni-Mol:unimolv1
2023-06-14 02:46:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5988, val_loss: 0.8144, val_auc: 0.7931, lr: 0.000098, 2.7s
2023-06-14 02:46:41 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4483, val_loss: 0.5561, val_auc: 0.8473, lr: 0.000093, 2.7s
2023-06-14 02:46:45 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3328, val_loss: 0.6250, val_auc: 0.8385, lr: 0.000088, 2.7s
2023-06-14 02:46:47 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.2436, val_loss: 0.6084, val_auc: 0.8253, lr: 0.000082, 2.7s
2023-06-14 02:46:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.2119, val_loss: 0.6684, val_auc: 0.8456, lr: 0.000077, 2.7s
2023-06-14 02:46:53 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.2369, val_loss: 0.6706, val_auc: 0.8610, lr: 0.000072, 2.7s
2023-06-14 02:46:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.1869, val_loss: 0.7756, val_auc: 0.8099, lr: 0.000067, 2.7s
2023-06-14 02:46:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.1458, val_loss: 0.8236, val_auc: 0.8452, lr: 0.000062, 2.7s
2023-06-14 02:47:01 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1093, val_loss: 0.7797, val_auc: 0.8485, lr: 0.000057, 2.7s
2023-06-14 02:47:04 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.0947, val_loss: 0.9176, val_auc: 0.8310, lr: 0.000052, 2.7s
2023-06-14 02:47:06 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.0671, val_loss: 0.9215, val_auc: 0.8627, lr: 0.000046, 2.7s
2023-06-14 02:47:10 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.0498, val_loss: 0.9356, val_auc: 0.8537, lr: 0.000041, 2.7s
2023-06-14 02:47:13 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0369, val_loss: 0.9357, val_auc: 0.8632, lr: 0.000036, 2.7s
2023-06-14 02:47:16 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0424, val_loss: 0.8700, val_auc: 0.8622, lr: 0.000031, 2.7s
2023-06-14 02:47:19 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0263, val_loss: 0.7906, val_auc: 0.8590, lr: 0.000026, 2.7s
2023-06-14 02:47:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.0348, val_loss: 0.7833, val_auc: 0.8738, lr: 0.000021, 2.7s
2023-06-14 02:47:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.0260, val_loss: 0.8176, val_auc: 0.8691, lr: 0.000015, 2.7s
2023-06-14 02:47:27 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.0295, val_loss: 0.9082, val_auc: 0.8686, lr: 0.000010, 2.7s
2023-06-14 02:47:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.0164, val_loss: 0.8566, val_auc: 0.8665, lr: 0.000005, 2.7s
2023-06-14 02:47:33 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.0340, val_loss: 0.8434, val_auc: 0.8667, lr: 0.000000, 2.7s
2023-06-14 02:47:35 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:47:35 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 0, result {'auc': 0.8738162878787878, 'auroc': 0.8738162878787878, 'auprc': 0.9180916303362129, 'log_loss': 0.7894133974818812, 'acc': 0.8642857142857143, 'f1_score': 0.9035532994923858, 'mcc': 0.6776151285059123, 'precision': 0.8811881188118812, 'recall': 0.9270833333333334, 'cohen_kappa': 0.6751343429408891, 'f1_bst': 0.9035532994923858, 'acc_bst': 0.8642857142857143}
2023-06-14 02:47:35 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:47:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5805, val_loss: 0.5399, val_auc: 0.8656, lr: 0.000098, 2.7s
2023-06-14 02:47:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4061, val_loss: 0.2882, val_auc: 0.9128, lr: 0.000093, 2.7s
2023-06-14 02:47:45 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3470, val_loss: 0.3554, val_auc: 0.9306, lr: 0.000088, 2.7s
2023-06-14 02:47:48 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3274, val_loss: 0.3748, val_auc: 0.9507, lr: 0.000082, 2.7s
2023-06-14 02:47:52 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.2655, val_loss: 0.4945, val_auc: 0.9409, lr: 0.000077, 2.7s
2023-06-14 02:47:54 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.2481, val_loss: 0.3371, val_auc: 0.9407, lr: 0.000072, 2.7s
2023-06-14 02:47:57 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.2244, val_loss: 0.2744, val_auc: 0.9386, lr: 0.000067, 2.7s
2023-06-14 02:48:00 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.2061, val_loss: 0.3402, val_auc: 0.9427, lr: 0.000062, 2.7s
2023-06-14 02:48:02 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1204, val_loss: 0.3829, val_auc: 0.9407, lr: 0.000057, 2.7s
2023-06-14 02:48:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.0960, val_loss: 0.3442, val_auc: 0.9481, lr: 0.000052, 2.7s
2023-06-14 02:48:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.0934, val_loss: 0.3292, val_auc: 0.9283, lr: 0.000046, 2.7s
2023-06-14 02:48:10 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.0907, val_loss: 0.4697, val_auc: 0.9143, lr: 0.000041, 2.7s
2023-06-14 02:48:13 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0647, val_loss: 0.4986, val_auc: 0.9236, lr: 0.000036, 2.7s
2023-06-14 02:48:16 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0372, val_loss: 0.5158, val_auc: 0.9133, lr: 0.000031, 2.7s
2023-06-14 02:48:16 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 14
2023-06-14 02:48:17 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:48:17 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 1, result {'auc': 0.9507223942208464, 'auroc': 0.9507223942208464, 'auprc': 0.9811265587299393, 'log_loss': 0.38524416667143146, 'acc': 0.8428571428571429, 'f1_score': 0.9017857142857143, 'mcc': 0.581323387800976, 'precision': 0.8278688524590164, 'recall': 0.9901960784313726, 'cohen_kappa': 0.5241038318912237, 'f1_bst': 0.9017857142857143, 'acc_bst': 0.8428571428571429}
2023-06-14 02:48:18 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:48:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5414, val_loss: 0.4098, val_auc: 0.8363, lr: 0.000098, 2.7s
2023-06-14 02:48:24 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4261, val_loss: 0.3522, val_auc: 0.8740, lr: 0.000093, 2.7s
2023-06-14 02:48:28 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3373, val_loss: 0.3716, val_auc: 0.8799, lr: 0.000088, 2.7s
2023-06-14 02:48:31 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.2625, val_loss: 0.4613, val_auc: 0.8604, lr: 0.000082, 2.7s
2023-06-14 02:48:34 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.2225, val_loss: 0.5035, val_auc: 0.8743, lr: 0.000077, 2.7s
2023-06-14 02:48:36 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.1691, val_loss: 0.6352, val_auc: 0.8973, lr: 0.000072, 2.7s
2023-06-14 02:48:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.1727, val_loss: 0.6517, val_auc: 0.8651, lr: 0.000067, 2.7s
2023-06-14 02:48:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.1535, val_loss: 1.0178, val_auc: 0.8665, lr: 0.000062, 2.7s
2023-06-14 02:48:45 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1249, val_loss: 0.6401, val_auc: 0.8518, lr: 0.000057, 2.7s
2023-06-14 02:48:47 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.0929, val_loss: 0.6902, val_auc: 0.8649, lr: 0.000052, 2.6s
2023-06-14 02:48:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.0783, val_loss: 0.8127, val_auc: 0.8665, lr: 0.000046, 2.7s
2023-06-14 02:48:53 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.0901, val_loss: 0.7885, val_auc: 0.8613, lr: 0.000041, 2.7s
2023-06-14 02:48:55 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0740, val_loss: 0.7836, val_auc: 0.8629, lr: 0.000036, 2.7s
2023-06-14 02:48:58 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0423, val_loss: 0.7725, val_auc: 0.8876, lr: 0.000031, 2.7s
2023-06-14 02:49:01 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0615, val_loss: 0.8764, val_auc: 0.8732, lr: 0.000026, 2.7s
2023-06-14 02:49:03 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.0513, val_loss: 0.9115, val_auc: 0.8726, lr: 0.000021, 2.7s
2023-06-14 02:49:03 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 16
2023-06-14 02:49:05 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:49:05 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 2, result {'auc': 0.8973362930077691, 'auroc': 0.8973362930077691, 'auprc': 0.9638958402808604, 'log_loss': 0.653131303300948, 'acc': 0.8428571428571429, 'f1_score': 0.8942307692307693, 'mcc': 0.5907650492186877, 'precision': 0.9117647058823529, 'recall': 0.8773584905660378, 'cohen_kappa': 0.5891141942369263, 'f1_bst': 0.8942307692307693, 'acc_bst': 0.8428571428571429}
2023-06-14 02:49:06 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:49:09 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5849, val_loss: 0.2583, val_auc: 0.9409, lr: 0.000098, 2.7s
2023-06-14 02:49:12 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4871, val_loss: 0.2127, val_auc: 0.9426, lr: 0.000093, 2.7s
2023-06-14 02:49:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3820, val_loss: 0.5528, val_auc: 0.9377, lr: 0.000088, 2.7s
2023-06-14 02:49:18 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3674, val_loss: 0.1665, val_auc: 0.9544, lr: 0.000082, 2.7s
2023-06-14 02:49:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3041, val_loss: 0.1635, val_auc: 0.9586, lr: 0.000077, 2.7s
2023-06-14 02:49:24 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.2341, val_loss: 0.2142, val_auc: 0.9562, lr: 0.000072, 2.7s
2023-06-14 02:49:27 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.2023, val_loss: 0.2564, val_auc: 0.9405, lr: 0.000067, 2.7s
2023-06-14 02:49:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.1722, val_loss: 0.1650, val_auc: 0.9537, lr: 0.000062, 2.7s
2023-06-14 02:49:32 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1669, val_loss: 0.4475, val_auc: 0.9057, lr: 0.000057, 2.7s
2023-06-14 02:49:35 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.1157, val_loss: 0.4406, val_auc: 0.9043, lr: 0.000052, 2.7s
2023-06-14 02:49:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.1343, val_loss: 0.3423, val_auc: 0.9130, lr: 0.000046, 2.7s
2023-06-14 02:49:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.1062, val_loss: 0.4324, val_auc: 0.9068, lr: 0.000041, 2.7s
2023-06-14 02:49:43 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0911, val_loss: 0.3582, val_auc: 0.9096, lr: 0.000036, 2.7s
2023-06-14 02:49:46 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0629, val_loss: 0.3135, val_auc: 0.8675, lr: 0.000031, 2.7s
2023-06-14 02:49:48 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0535, val_loss: 0.3634, val_auc: 0.8633, lr: 0.000026, 2.7s
2023-06-14 02:49:48 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 15
2023-06-14 02:49:49 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:49:50 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 3, result {'auc': 0.9586086956521739, 'auroc': 0.9586086956521739, 'auprc': 0.9869959788590161, 'log_loss': 0.16752941969649068, 'acc': 0.9428571428571428, 'f1_score': 0.9658119658119659, 'mcc': 0.7965184258559546, 'precision': 0.9495798319327731, 'recall': 0.9826086956521739, 'cohen_kappa': 0.7922077922077921, 'f1_bst': 0.9658119658119659, 'acc_bst': 0.9428571428571428}
2023-06-14 02:49:50 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:49:53 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5732, val_loss: 0.5131, val_auc: 0.7979, lr: 0.000098, 2.7s
2023-06-14 02:49:57 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.3933, val_loss: 0.4352, val_auc: 0.8131, lr: 0.000093, 2.7s
2023-06-14 02:50:00 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.4225, val_loss: 0.4373, val_auc: 0.8402, lr: 0.000088, 2.8s
2023-06-14 02:50:03 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3468, val_loss: 0.4301, val_auc: 0.8355, lr: 0.000082, 2.8s
2023-06-14 02:50:06 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3166, val_loss: 0.4373, val_auc: 0.8472, lr: 0.000077, 2.7s
2023-06-14 02:50:09 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.1950, val_loss: 0.5074, val_auc: 0.8863, lr: 0.000072, 2.7s
2023-06-14 02:50:13 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.1337, val_loss: 0.8005, val_auc: 0.8709, lr: 0.000067, 2.7s
2023-06-14 02:50:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.1110, val_loss: 0.7644, val_auc: 0.8657, lr: 0.000062, 2.7s
2023-06-14 02:50:18 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.0788, val_loss: 0.8868, val_auc: 0.8727, lr: 0.000057, 2.7s
2023-06-14 02:50:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.0553, val_loss: 0.9180, val_auc: 0.8764, lr: 0.000052, 2.7s
2023-06-14 02:50:24 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.0484, val_loss: 1.1203, val_auc: 0.8626, lr: 0.000046, 2.8s
2023-06-14 02:50:26 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.0274, val_loss: 1.1687, val_auc: 0.8598, lr: 0.000041, 2.8s
2023-06-14 02:50:29 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0070, val_loss: 1.2084, val_auc: 0.8594, lr: 0.000036, 2.7s
2023-06-14 02:50:32 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0159, val_loss: 1.2632, val_auc: 0.8585, lr: 0.000031, 2.7s
2023-06-14 02:50:34 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0263, val_loss: 1.3071, val_auc: 0.8571, lr: 0.000026, 2.7s
2023-06-14 02:50:37 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.0037, val_loss: 1.3253, val_auc: 0.8570, lr: 0.000021, 2.8s
2023-06-14 02:50:37 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 16
2023-06-14 02:50:38 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:50:39 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 4, result {'auc': 0.8862688900468995, 'auroc': 0.8862688900468995, 'auprc': 0.9425293474468884, 'log_loss': 0.5122246753471307, 'acc': 0.8129496402877698, 'f1_score': 0.8673469387755102, 'mcc': 0.5542584824780713, 'precision': 0.8947368421052632, 'recall': 0.8415841584158416, 'cohen_kappa': 0.5512788676434071, 'f1_bst': 0.8673469387755102, 'acc_bst': 0.8129496402877698}
2023-06-14 02:50:39 | unimol/models/nnmodel.py | 135 | INFO | Uni-Mol(QSAR) | Uni-Mol metrics score: 
{'auc': 0.8758433605500645, 'auroc': 0.8758433605500645, 'auprc': 0.9306838454908142, 'log_loss': 0.5014932619089505, 'acc': 0.8612303290414879, 'f1_score': 0.9084041548630785, 'mcc': 0.6243557808469459, 'precision': 0.8923933209647495, 'recall': 0.925, 'cohen_kappa': 0.6226479149158787, 'f1_bst': 0.9084041548630785, 'acc_bst': 0.8612303290414879}
2023-06-14 02:50:39 | unimol/models/nnmodel.py | 136 | INFO | Uni-Mol(QSAR) | Uni-Mol & Metric result saved!
2023-06-14 02:50:39 | unimol/utils/metrics.py | 288 | INFO | Uni-Mol(QSAR) | metrics for threshold: accuracy_score
2023-06-14 02:50:39 | unimol/utils/metrics.py | 301 | INFO | Uni-Mol(QSAR) | best threshold: 0.7891003276515556, metrics: 0.8683834048640916
learning_rate:  0.0001
交叉验证结果: 0.8758433605500645
2023-06-14 02:50:39 | unimol/data/conformer.py | 56 | INFO | Uni-Mol(QSAR) | Start generating conformers...
699it [00:22, 30.94it/s]
2023-06-14 02:51:02 | unimol/data/conformer.py | 60 | INFO | Uni-Mol(QSAR) | Failed to generate conformers for 0.00% of molecules.
2023-06-14 02:51:02 | unimol/data/conformer.py | 62 | INFO | Uni-Mol(QSAR) | Failed to generate 3d conformers for 0.29% of molecules.
2023-06-14 02:51:02 | unimol/train.py | 86 | INFO | Uni-Mol(QSAR) | Output directory already exists: ./learning_rate_0.0004
2023-06-14 02:51:02 | unimol/train.py | 87 | INFO | Uni-Mol(QSAR) | Warning: Overwrite output directory: ./learning_rate_0.0004
2023-06-14 02:51:02 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:51:03 | unimol/models/nnmodel.py | 100 | INFO | Uni-Mol(QSAR) | start training Uni-Mol:unimolv1
2023-06-14 02:51:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5451, val_loss: 0.5072, val_auc: 0.7966, lr: 0.000392, 2.7s
2023-06-14 02:51:09 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4068, val_loss: 0.4936, val_auc: 0.8620, lr: 0.000371, 2.7s
2023-06-14 02:51:12 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3445, val_loss: 0.5849, val_auc: 0.8127, lr: 0.000350, 2.7s
2023-06-14 02:51:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.2745, val_loss: 0.6915, val_auc: 0.7902, lr: 0.000330, 2.7s
2023-06-14 02:51:18 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.2419, val_loss: 0.6014, val_auc: 0.8288, lr: 0.000309, 2.7s
2023-06-14 02:51:20 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.2688, val_loss: 0.5843, val_auc: 0.7675, lr: 0.000288, 2.7s
2023-06-14 02:51:23 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.2274, val_loss: 0.6594, val_auc: 0.8350, lr: 0.000268, 2.7s
2023-06-14 02:51:26 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.1630, val_loss: 0.8033, val_auc: 0.8688, lr: 0.000247, 2.7s
2023-06-14 02:51:29 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1556, val_loss: 0.6205, val_auc: 0.8802, lr: 0.000227, 2.7s
2023-06-14 02:51:32 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.1300, val_loss: 0.7295, val_auc: 0.8570, lr: 0.000206, 2.7s
2023-06-14 02:51:35 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.0586, val_loss: 0.8561, val_auc: 0.8755, lr: 0.000185, 2.7s
2023-06-14 02:51:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.0547, val_loss: 0.6987, val_auc: 0.8788, lr: 0.000165, 2.7s
2023-06-14 02:51:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0567, val_loss: 0.7120, val_auc: 0.8991, lr: 0.000144, 2.7s
2023-06-14 02:51:44 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0366, val_loss: 0.8265, val_auc: 0.8859, lr: 0.000124, 2.7s
2023-06-14 02:51:46 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0188, val_loss: 0.8605, val_auc: 0.8790, lr: 0.000103, 2.7s
2023-06-14 02:51:49 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.0120, val_loss: 0.8271, val_auc: 0.8759, lr: 0.000082, 2.7s
2023-06-14 02:51:52 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.0099, val_loss: 0.8494, val_auc: 0.8778, lr: 0.000062, 2.7s
2023-06-14 02:51:54 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.0077, val_loss: 0.8578, val_auc: 0.8771, lr: 0.000041, 2.7s
2023-06-14 02:51:57 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.0064, val_loss: 0.8958, val_auc: 0.8769, lr: 0.000021, 2.7s
2023-06-14 02:52:00 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.0100, val_loss: 0.8958, val_auc: 0.8776, lr: 0.000000, 2.7s
2023-06-14 02:52:01 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:52:01 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 0, result {'auc': 0.8991477272727273, 'auroc': 0.8991477272727273, 'auprc': 0.9472968420875154, 'log_loss': 0.7134734748197453, 'acc': 0.8571428571428571, 'f1_score': 0.8958333333333334, 'mcc': 0.6685606060606061, 'precision': 0.8958333333333334, 'recall': 0.8958333333333334, 'cohen_kappa': 0.6685606060606061, 'f1_bst': 0.8958333333333334, 'acc_bst': 0.8571428571428571}
2023-06-14 02:52:02 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:52:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5659, val_loss: 0.4545, val_auc: 0.8682, lr: 0.000392, 2.7s
2023-06-14 02:52:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4786, val_loss: 0.4274, val_auc: 0.8756, lr: 0.000371, 2.7s
2023-06-14 02:52:11 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.4084, val_loss: 0.3870, val_auc: 0.8878, lr: 0.000350, 2.7s
2023-06-14 02:52:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3859, val_loss: 0.3597, val_auc: 0.9133, lr: 0.000330, 2.7s
2023-06-14 02:52:18 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3842, val_loss: 0.5086, val_auc: 0.9045, lr: 0.000309, 2.7s
2023-06-14 02:52:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.3320, val_loss: 0.2968, val_auc: 0.9337, lr: 0.000288, 2.7s
2023-06-14 02:52:24 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.2531, val_loss: 0.4743, val_auc: 0.9156, lr: 0.000268, 2.7s
2023-06-14 02:52:27 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.2077, val_loss: 0.3384, val_auc: 0.9309, lr: 0.000247, 2.7s
2023-06-14 02:52:29 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1728, val_loss: 0.3267, val_auc: 0.9241, lr: 0.000227, 2.7s
2023-06-14 02:52:32 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.1457, val_loss: 0.3183, val_auc: 0.9487, lr: 0.000206, 2.7s
2023-06-14 02:52:35 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.1060, val_loss: 0.4225, val_auc: 0.9355, lr: 0.000185, 2.7s
2023-06-14 02:52:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.0832, val_loss: 0.3354, val_auc: 0.9404, lr: 0.000165, 2.7s
2023-06-14 02:52:41 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0806, val_loss: 0.4343, val_auc: 0.9420, lr: 0.000144, 2.7s
2023-06-14 02:52:43 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0556, val_loss: 0.6673, val_auc: 0.9151, lr: 0.000124, 2.7s
2023-06-14 02:52:46 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0563, val_loss: 0.5075, val_auc: 0.9164, lr: 0.000103, 2.7s
2023-06-14 02:52:49 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.0538, val_loss: 0.6048, val_auc: 0.9100, lr: 0.000082, 2.7s
2023-06-14 02:52:51 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.0298, val_loss: 0.5631, val_auc: 0.9061, lr: 0.000062, 2.7s
2023-06-14 02:52:54 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.0205, val_loss: 0.5263, val_auc: 0.9168, lr: 0.000041, 2.7s
2023-06-14 02:52:57 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.0337, val_loss: 0.5412, val_auc: 0.9136, lr: 0.000021, 2.7s
2023-06-14 02:52:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.0160, val_loss: 0.5401, val_auc: 0.9151, lr: 0.000000, 2.7s
2023-06-14 02:52:59 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 20
2023-06-14 02:53:01 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:53:01 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 1, result {'auc': 0.9486584107327142, 'auroc': 0.9486584107327142, 'auprc': 0.9803465753927931, 'log_loss': 0.32716968444541894, 'acc': 0.8857142857142857, 'f1_score': 0.9223300970873786, 'mcc': 0.7066677163817273, 'precision': 0.9134615384615384, 'recall': 0.9313725490196079, 'cohen_kappa': 0.7061909758656872, 'f1_bst': 0.9223300970873786, 'acc_bst': 0.8857142857142857}
2023-06-14 02:53:02 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:53:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6260, val_loss: 0.8598, val_auc: 0.7639, lr: 0.000392, 2.7s
2023-06-14 02:53:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5588, val_loss: 0.4338, val_auc: 0.7991, lr: 0.000371, 2.8s
2023-06-14 02:53:11 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3792, val_loss: 0.4754, val_auc: 0.8282, lr: 0.000350, 2.8s
2023-06-14 02:53:14 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3652, val_loss: 0.4677, val_auc: 0.8310, lr: 0.000330, 2.7s
2023-06-14 02:53:18 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.2879, val_loss: 0.5259, val_auc: 0.8257, lr: 0.000309, 2.7s
2023-06-14 02:53:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.2628, val_loss: 0.5549, val_auc: 0.8432, lr: 0.000288, 2.7s
2023-06-14 02:53:24 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.2194, val_loss: 0.5253, val_auc: 0.8435, lr: 0.000268, 2.7s
2023-06-14 02:53:27 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.1775, val_loss: 0.7019, val_auc: 0.8263, lr: 0.000247, 2.7s
2023-06-14 02:53:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1633, val_loss: 0.6165, val_auc: 0.8332, lr: 0.000227, 2.7s
2023-06-14 02:53:32 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.1531, val_loss: 0.7391, val_auc: 0.7963, lr: 0.000206, 2.7s
2023-06-14 02:53:35 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.1079, val_loss: 0.7109, val_auc: 0.7944, lr: 0.000185, 2.7s
2023-06-14 02:53:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.1168, val_loss: 0.6714, val_auc: 0.8319, lr: 0.000165, 2.7s
2023-06-14 02:53:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.1011, val_loss: 0.6214, val_auc: 0.7808, lr: 0.000144, 2.7s
2023-06-14 02:53:43 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0706, val_loss: 0.8131, val_auc: 0.7900, lr: 0.000124, 2.7s
2023-06-14 02:53:46 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0676, val_loss: 0.7180, val_auc: 0.7913, lr: 0.000103, 2.7s
2023-06-14 02:53:48 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.0488, val_loss: 0.8137, val_auc: 0.7876, lr: 0.000082, 2.7s
2023-06-14 02:53:51 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.0442, val_loss: 0.8700, val_auc: 0.7952, lr: 0.000062, 2.7s
2023-06-14 02:53:51 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 17
2023-06-14 02:53:52 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:53:53 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 2, result {'auc': 0.8435072142064373, 'auroc': 0.8435072142064373, 'auprc': 0.9388996222570902, 'log_loss': 0.5394861050299369, 'acc': 0.85, 'f1_score': 0.9074889867841409, 'mcc': 0.5537661947813969, 'precision': 0.8512396694214877, 'recall': 0.9716981132075472, 'cohen_kappa': 0.5202349869451697, 'f1_bst': 0.9074889867841409, 'acc_bst': 0.85}
2023-06-14 02:53:53 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:53:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5837, val_loss: 0.2635, val_auc: 0.9426, lr: 0.000392, 2.7s
2023-06-14 02:53:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5030, val_loss: 0.2465, val_auc: 0.9144, lr: 0.000371, 2.7s
2023-06-14 02:54:02 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3978, val_loss: 0.2368, val_auc: 0.9471, lr: 0.000350, 2.7s
2023-06-14 02:54:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3284, val_loss: 0.1704, val_auc: 0.9471, lr: 0.000330, 2.7s
2023-06-14 02:54:09 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3308, val_loss: 0.1668, val_auc: 0.9680, lr: 0.000309, 2.7s
2023-06-14 02:54:12 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.2732, val_loss: 0.4123, val_auc: 0.9391, lr: 0.000288, 2.7s
2023-06-14 02:54:14 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.2286, val_loss: 0.6993, val_auc: 0.9367, lr: 0.000268, 2.7s
2023-06-14 02:54:17 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.2082, val_loss: 0.2684, val_auc: 0.9057, lr: 0.000247, 2.7s
2023-06-14 02:54:20 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.1911, val_loss: 0.2994, val_auc: 0.8967, lr: 0.000227, 2.7s
2023-06-14 02:54:22 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.1436, val_loss: 0.2890, val_auc: 0.9395, lr: 0.000206, 2.7s
2023-06-14 02:54:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.1075, val_loss: 0.4782, val_auc: 0.9343, lr: 0.000185, 2.7s
2023-06-14 02:54:28 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.1322, val_loss: 0.3572, val_auc: 0.9621, lr: 0.000165, 2.7s
2023-06-14 02:54:31 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0881, val_loss: 0.3502, val_auc: 0.9071, lr: 0.000144, 2.7s
2023-06-14 02:54:33 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0912, val_loss: 0.4249, val_auc: 0.9304, lr: 0.000124, 2.7s
2023-06-14 02:54:36 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0536, val_loss: 0.3661, val_auc: 0.9437, lr: 0.000103, 2.7s
2023-06-14 02:54:36 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 15
2023-06-14 02:54:37 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:54:37 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 3, result {'auc': 0.968, 'auroc': 0.968, 'auprc': 0.9915244868468799, 'log_loss': 0.16911987428154265, 'acc': 0.9714285714285714, 'f1_score': 0.9827586206896551, 'mcc': 0.9006000294086005, 'precision': 0.9743589743589743, 'recall': 0.991304347826087, 'cohen_kappa': 0.8994614003590664, 'f1_bst': 0.9827586206896551, 'acc_bst': 0.9714285714285714}
2023-06-14 02:54:38 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:54:41 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.5640, val_loss: 0.4266, val_auc: 0.8163, lr: 0.000392, 2.8s
2023-06-14 02:54:44 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4794, val_loss: 0.4076, val_auc: 0.8365, lr: 0.000371, 2.7s
2023-06-14 02:54:48 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.3632, val_loss: 0.4233, val_auc: 0.8220, lr: 0.000351, 2.7s
2023-06-14 02:54:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.3034, val_loss: 0.4292, val_auc: 0.8308, lr: 0.000330, 2.7s
2023-06-14 02:54:53 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.3048, val_loss: 0.6536, val_auc: 0.7923, lr: 0.000309, 2.9s
2023-06-14 02:54:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.2762, val_loss: 0.4471, val_auc: 0.8219, lr: 0.000289, 2.7s
2023-06-14 02:54:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.2843, val_loss: 0.5419, val_auc: 0.8207, lr: 0.000268, 2.7s
2023-06-14 02:55:01 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.2338, val_loss: 0.6088, val_auc: 0.8370, lr: 0.000247, 2.8s
2023-06-14 02:55:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.2085, val_loss: 0.7374, val_auc: 0.7970, lr: 0.000227, 2.8s
2023-06-14 02:55:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.1378, val_loss: 0.7582, val_auc: 0.8323, lr: 0.000206, 2.8s
2023-06-14 02:55:10 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.0854, val_loss: 0.8763, val_auc: 0.8078, lr: 0.000186, 2.8s
2023-06-14 02:55:13 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.0740, val_loss: 1.0278, val_auc: 0.7775, lr: 0.000165, 2.8s
2023-06-14 02:55:16 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.0491, val_loss: 0.9963, val_auc: 0.8008, lr: 0.000144, 2.8s
2023-06-14 02:55:19 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.0198, val_loss: 1.1311, val_auc: 0.7942, lr: 0.000124, 2.8s
2023-06-14 02:55:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.0339, val_loss: 1.1366, val_auc: 0.7922, lr: 0.000103, 2.7s
2023-06-14 02:55:24 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.0108, val_loss: 1.3071, val_auc: 0.7873, lr: 0.000082, 2.7s
2023-06-14 02:55:27 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.0009, val_loss: 1.3269, val_auc: 0.7884, lr: 0.000062, 2.8s
2023-06-14 02:55:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.0007, val_loss: 1.3722, val_auc: 0.7805, lr: 0.000041, 2.8s
2023-06-14 02:55:30 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 18
2023-06-14 02:55:30 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:55:30 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 4, result {'auc': 0.8370244919228765, 'auroc': 0.8370244919228765, 'auprc': 0.8970388344320352, 'log_loss': 0.6180428940327101, 'acc': 0.8345323741007195, 'f1_score': 0.8888888888888888, 'mcc': 0.5682223833524765, 'precision': 0.8679245283018868, 'recall': 0.9108910891089109, 'cohen_kappa': 0.5656840103246842, 'f1_bst': 0.8888888888888888, 'acc_bst': 0.8345323741007195}
2023-06-14 02:55:30 | unimol/models/nnmodel.py | 135 | INFO | Uni-Mol(QSAR) | Uni-Mol metrics score: 
{'auc': 0.8677750322303396, 'auroc': 0.8677750322303396, 'auprc': 0.9346366392339024, 'log_loss': 0.4732515617614833, 'acc': 0.8798283261802575, 'f1_score': 0.9210526315789475, 'mcc': 0.673087186645002, 'precision': 0.9007352941176471, 'recall': 0.9423076923076923, 'cohen_kappa': 0.6700903492605745, 'f1_bst': 0.9210526315789475, 'acc_bst': 0.8798283261802575}
2023-06-14 02:55:30 | unimol/models/nnmodel.py | 136 | INFO | Uni-Mol(QSAR) | Uni-Mol & Metric result saved!
2023-06-14 02:55:30 | unimol/utils/metrics.py | 288 | INFO | Uni-Mol(QSAR) | metrics for threshold: accuracy_score
2023-06-14 02:55:30 | unimol/utils/metrics.py | 301 | INFO | Uni-Mol(QSAR) | best threshold: 0.6318812173803484, metrics: 0.8841201716738197
learning_rate:  0.0004
交叉验证结果: 0.8677750322303396
2023-06-14 02:55:30 | unimol/data/conformer.py | 56 | INFO | Uni-Mol(QSAR) | Start generating conformers...
699it [00:22, 31.69it/s]
2023-06-14 02:55:52 | unimol/data/conformer.py | 60 | INFO | Uni-Mol(QSAR) | Failed to generate conformers for 0.00% of molecules.
2023-06-14 02:55:52 | unimol/data/conformer.py | 62 | INFO | Uni-Mol(QSAR) | Failed to generate 3d conformers for 0.29% of molecules.
2023-06-14 02:55:52 | unimol/train.py | 86 | INFO | Uni-Mol(QSAR) | Output directory already exists: ./learning_rate_0.001
2023-06-14 02:55:52 | unimol/train.py | 87 | INFO | Uni-Mol(QSAR) | Warning: Overwrite output directory: ./learning_rate_0.001
2023-06-14 02:55:53 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:55:53 | unimol/models/nnmodel.py | 100 | INFO | Uni-Mol(QSAR) | start training Uni-Mol:unimolv1
2023-06-14 02:55:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6226, val_loss: 0.5652, val_auc: 0.8203, lr: 0.000979, 2.7s
2023-06-14 02:55:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.4891, val_loss: 0.8064, val_auc: 0.8170, lr: 0.000927, 2.7s
2023-06-14 02:56:02 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.5804, val_loss: 0.5168, val_auc: 0.8104, lr: 0.000876, 2.7s
2023-06-14 02:56:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.4916, val_loss: 0.4605, val_auc: 0.8333, lr: 0.000824, 2.7s
2023-06-14 02:56:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.4855, val_loss: 0.4982, val_auc: 0.8179, lr: 0.000773, 2.7s
2023-06-14 02:56:11 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.4516, val_loss: 0.5261, val_auc: 0.7952, lr: 0.000721, 2.7s
2023-06-14 02:56:13 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.4119, val_loss: 0.5566, val_auc: 0.8087, lr: 0.000670, 2.7s
2023-06-14 02:56:16 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.4073, val_loss: 0.4950, val_auc: 0.8113, lr: 0.000618, 2.7s
2023-06-14 02:56:19 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.3983, val_loss: 0.5005, val_auc: 0.8310, lr: 0.000567, 2.7s
2023-06-14 02:56:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.3898, val_loss: 0.5062, val_auc: 0.8371, lr: 0.000515, 2.7s
2023-06-14 02:56:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.4168, val_loss: 0.4979, val_auc: 0.8298, lr: 0.000464, 2.7s
2023-06-14 02:56:28 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.3965, val_loss: 0.4979, val_auc: 0.8172, lr: 0.000412, 2.7s
2023-06-14 02:56:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.3503, val_loss: 0.5814, val_auc: 0.8288, lr: 0.000361, 2.7s
2023-06-14 02:56:33 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.3569, val_loss: 0.5388, val_auc: 0.8243, lr: 0.000309, 2.7s
2023-06-14 02:56:36 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.3444, val_loss: 0.5477, val_auc: 0.8343, lr: 0.000258, 2.7s
2023-06-14 02:56:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.3428, val_loss: 0.5590, val_auc: 0.8217, lr: 0.000206, 2.7s
2023-06-14 02:56:41 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.3343, val_loss: 0.5417, val_auc: 0.8168, lr: 0.000155, 2.7s
2023-06-14 02:56:44 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.3411, val_loss: 0.5850, val_auc: 0.8286, lr: 0.000103, 2.7s
2023-06-14 02:56:46 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.3275, val_loss: 0.5503, val_auc: 0.8189, lr: 0.000052, 2.7s
2023-06-14 02:56:49 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.3204, val_loss: 0.5558, val_auc: 0.8248, lr: 0.000000, 2.7s
2023-06-14 02:56:49 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 20
2023-06-14 02:56:50 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:56:50 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 0, result {'auc': 0.8371212121212122, 'auroc': 0.8371212121212122, 'auprc': 0.927828718386458, 'log_loss': 0.5129416627809406, 'acc': 0.7428571428571429, 'f1_score': 0.8269230769230769, 'mcc': 0.3538880365655816, 'precision': 0.7678571428571429, 'recall': 0.8958333333333334, 'cohen_kappa': 0.3382352941176471, 'f1_bst': 0.8269230769230769, 'acc_bst': 0.7428571428571429}
2023-06-14 02:56:51 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:56:54 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6096, val_loss: 0.5161, val_auc: 0.7967, lr: 0.000979, 2.7s
2023-06-14 02:56:57 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5683, val_loss: 0.6973, val_auc: 0.8728, lr: 0.000927, 2.7s
2023-06-14 02:57:00 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.5385, val_loss: 0.5132, val_auc: 0.8357, lr: 0.000876, 2.7s
2023-06-14 02:57:03 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.4968, val_loss: 0.4258, val_auc: 0.8522, lr: 0.000824, 2.7s
2023-06-14 02:57:06 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.4180, val_loss: 0.4885, val_auc: 0.8710, lr: 0.000773, 2.7s
2023-06-14 02:57:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.4193, val_loss: 0.3824, val_auc: 0.8687, lr: 0.000721, 2.7s
2023-06-14 02:57:11 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.4101, val_loss: 0.6658, val_auc: 0.8947, lr: 0.000670, 2.7s
2023-06-14 02:57:14 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.4931, val_loss: 0.3713, val_auc: 0.8914, lr: 0.000618, 2.7s
2023-06-14 02:57:17 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.3876, val_loss: 0.4258, val_auc: 0.8834, lr: 0.000567, 2.7s
2023-06-14 02:57:20 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.3866, val_loss: 0.3524, val_auc: 0.8950, lr: 0.000515, 2.7s
2023-06-14 02:57:23 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.3649, val_loss: 0.3950, val_auc: 0.8762, lr: 0.000464, 2.7s
2023-06-14 02:57:26 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.3468, val_loss: 0.3996, val_auc: 0.8769, lr: 0.000412, 2.7s
2023-06-14 02:57:29 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.3547, val_loss: 0.3633, val_auc: 0.8800, lr: 0.000361, 2.6s
2023-06-14 02:57:31 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.3214, val_loss: 0.3593, val_auc: 0.8940, lr: 0.000309, 2.6s
2023-06-14 02:57:34 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.3093, val_loss: 0.3534, val_auc: 0.9082, lr: 0.000258, 2.6s
2023-06-14 02:57:37 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.3450, val_loss: 0.2905, val_auc: 0.9355, lr: 0.000206, 2.7s
2023-06-14 02:57:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.2656, val_loss: 0.3242, val_auc: 0.9334, lr: 0.000155, 2.7s
2023-06-14 02:57:43 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.2616, val_loss: 0.2936, val_auc: 0.9389, lr: 0.000103, 2.7s
2023-06-14 02:57:47 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.2315, val_loss: 0.2918, val_auc: 0.9458, lr: 0.000052, 2.7s
2023-06-14 02:57:50 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.2041, val_loss: 0.2811, val_auc: 0.9476, lr: 0.000000, 2.7s
2023-06-14 02:57:52 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:57:52 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 1, result {'auc': 0.947626418988648, 'auroc': 0.947626418988648, 'auprc': 0.9820347458047106, 'log_loss': 0.2874043566041759, 'acc': 0.8785714285714286, 'f1_score': 0.9178743961352657, 'mcc': 0.6862450236920773, 'precision': 0.9047619047619048, 'recall': 0.9313725490196079, 'cohen_kappa': 0.6851851851851851, 'f1_bst': 0.9178743961352657, 'acc_bst': 0.8785714285714286}
2023-06-14 02:57:53 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:57:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6466, val_loss: 0.5257, val_auc: 0.7805, lr: 0.000979, 2.7s
2023-06-14 02:57:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5252, val_loss: 0.4977, val_auc: 0.7483, lr: 0.000927, 2.7s
2023-06-14 02:58:02 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.5321, val_loss: 0.5620, val_auc: 0.7605, lr: 0.000876, 2.7s
2023-06-14 02:58:04 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.5084, val_loss: 0.4872, val_auc: 0.8027, lr: 0.000824, 2.6s
2023-06-14 02:58:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.4322, val_loss: 0.4626, val_auc: 0.7961, lr: 0.000773, 2.7s
2023-06-14 02:58:11 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.4143, val_loss: 0.4710, val_auc: 0.8063, lr: 0.000721, 2.7s
2023-06-14 02:58:14 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.4001, val_loss: 0.4809, val_auc: 0.7503, lr: 0.000670, 2.7s
2023-06-14 02:58:16 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.3982, val_loss: 0.5304, val_auc: 0.7980, lr: 0.000618, 2.7s
2023-06-14 02:58:19 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.4073, val_loss: 0.4707, val_auc: 0.7922, lr: 0.000567, 2.7s
2023-06-14 02:58:22 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.3689, val_loss: 0.4546, val_auc: 0.7866, lr: 0.000515, 2.7s
2023-06-14 02:58:24 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.3604, val_loss: 0.4949, val_auc: 0.7925, lr: 0.000464, 2.7s
2023-06-14 02:58:27 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.3580, val_loss: 0.4726, val_auc: 0.7966, lr: 0.000412, 2.7s
2023-06-14 02:58:30 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.3530, val_loss: 0.4752, val_auc: 0.7750, lr: 0.000361, 2.7s
2023-06-14 02:58:33 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.3194, val_loss: 0.5060, val_auc: 0.7693, lr: 0.000309, 2.7s
2023-06-14 02:58:35 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.3082, val_loss: 0.4975, val_auc: 0.7741, lr: 0.000258, 2.6s
2023-06-14 02:58:38 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.2740, val_loss: 0.5810, val_auc: 0.7592, lr: 0.000206, 2.7s
2023-06-14 02:58:38 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 16
2023-06-14 02:58:39 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:58:39 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 2, result {'auc': 0.8063263041065483, 'auroc': 0.8063263041065483, 'auprc': 0.9230842528475022, 'log_loss': 0.47241474839725667, 'acc': 0.8142857142857143, 'f1_score': 0.8839285714285714, 'mcc': 0.4420098590221632, 'precision': 0.8389830508474576, 'recall': 0.9339622641509434, 'cohen_kappa': 0.42622950819672134, 'f1_bst': 0.8839285714285714, 'acc_bst': 0.8142857142857143}
2023-06-14 02:58:39 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:58:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6433, val_loss: 0.4441, val_auc: 0.9388, lr: 0.000979, 2.7s
2023-06-14 02:58:46 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5886, val_loss: 0.3424, val_auc: 0.8765, lr: 0.000927, 2.7s
2023-06-14 02:58:49 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.6425, val_loss: 0.4244, val_auc: 0.8922, lr: 0.000876, 2.7s
2023-06-14 02:58:51 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.5337, val_loss: 0.3538, val_auc: 0.9009, lr: 0.000824, 2.7s
2023-06-14 02:58:54 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.5154, val_loss: 0.3100, val_auc: 0.9089, lr: 0.000773, 2.7s
2023-06-14 02:58:56 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.5096, val_loss: 0.3517, val_auc: 0.9096, lr: 0.000721, 2.7s
2023-06-14 02:58:59 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.4614, val_loss: 0.3173, val_auc: 0.9200, lr: 0.000670, 2.7s
2023-06-14 02:59:02 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.4628, val_loss: 0.4890, val_auc: 0.8984, lr: 0.000618, 2.7s
2023-06-14 02:59:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.4667, val_loss: 0.3014, val_auc: 0.8977, lr: 0.000567, 2.7s
2023-06-14 02:59:07 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.4565, val_loss: 0.3012, val_auc: 0.8904, lr: 0.000515, 2.7s
2023-06-14 02:59:10 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.4358, val_loss: 0.3628, val_auc: 0.9082, lr: 0.000464, 2.7s
2023-06-14 02:59:10 | unimol/utils/metrics.py | 270 | WARNING | Uni-Mol(QSAR) | Early stopping at epoch: 11
2023-06-14 02:59:11 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 02:59:11 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 3, result {'auc': 0.9387826086956522, 'auroc': 0.9387826086956522, 'auprc': 0.9840810840145162, 'log_loss': 0.45406898063208373, 'acc': 0.8214285714285714, 'f1_score': 0.9019607843137255, 'mcc': 0.0, 'precision': 0.8214285714285714, 'recall': 1.0, 'cohen_kappa': 0.0, 'f1_bst': 0.9019607843137255, 'acc_bst': 0.8214285714285714}
2023-06-14 02:59:12 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 02:59:15 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [1/20] train_loss: 0.6550, val_loss: 0.6177, val_auc: 0.7375, lr: 0.000979, 2.7s
2023-06-14 02:59:19 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [2/20] train_loss: 0.5968, val_loss: 0.5773, val_auc: 0.2770, lr: 0.000928, 2.8s
2023-06-14 02:59:21 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [3/20] train_loss: 0.5860, val_loss: 0.5903, val_auc: 0.7858, lr: 0.000876, 2.8s
2023-06-14 02:59:25 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [4/20] train_loss: 0.5760, val_loss: 0.5773, val_auc: 0.7925, lr: 0.000825, 2.8s
2023-06-14 02:59:28 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [5/20] train_loss: 0.5723, val_loss: 0.5942, val_auc: 0.7978, lr: 0.000773, 2.8s
2023-06-14 02:59:31 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [6/20] train_loss: 0.5809, val_loss: 0.5778, val_auc: 0.7887, lr: 0.000722, 2.7s
2023-06-14 02:59:34 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [7/20] train_loss: 0.5868, val_loss: 0.5845, val_auc: 0.7714, lr: 0.000670, 2.7s
2023-06-14 02:59:37 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [8/20] train_loss: 0.5699, val_loss: 0.5863, val_auc: 0.7828, lr: 0.000619, 2.7s
2023-06-14 02:59:40 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [9/20] train_loss: 0.5671, val_loss: 0.5683, val_auc: 0.7417, lr: 0.000567, 2.7s
2023-06-14 02:59:42 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [10/20] train_loss: 0.5384, val_loss: 0.6055, val_auc: 0.7366, lr: 0.000515, 2.8s
2023-06-14 02:59:45 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [11/20] train_loss: 0.5025, val_loss: 0.5838, val_auc: 0.8308, lr: 0.000464, 2.7s
2023-06-14 02:59:49 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [12/20] train_loss: 0.4759, val_loss: 0.5640, val_auc: 0.7837, lr: 0.000412, 2.8s
2023-06-14 02:59:51 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [13/20] train_loss: 0.4469, val_loss: 0.4476, val_auc: 0.8279, lr: 0.000361, 2.8s
2023-06-14 02:59:54 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [14/20] train_loss: 0.4274, val_loss: 0.5753, val_auc: 0.7550, lr: 0.000309, 2.8s
2023-06-14 02:59:57 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [15/20] train_loss: 0.4160, val_loss: 0.4775, val_auc: 0.7688, lr: 0.000258, 2.8s
2023-06-14 03:00:00 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [16/20] train_loss: 0.3779, val_loss: 0.4659, val_auc: 0.7969, lr: 0.000206, 2.7s
2023-06-14 03:00:02 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [17/20] train_loss: 0.3747, val_loss: 0.5405, val_auc: 0.7781, lr: 0.000155, 2.8s
2023-06-14 03:00:05 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [18/20] train_loss: 0.3480, val_loss: 0.5107, val_auc: 0.7850, lr: 0.000103, 2.8s
2023-06-14 03:00:08 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [19/20] train_loss: 0.3381, val_loss: 0.5212, val_auc: 0.7901, lr: 0.000052, 2.8s
2023-06-14 03:00:11 | unimol/tasks/trainer.py | 156 | INFO | Uni-Mol(QSAR) | Epoch [20/20] train_loss: 0.3156, val_loss: 0.4876, val_auc: 0.7938, lr: 0.000000, 2.7s
2023-06-14 03:00:13 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 03:00:13 | unimol/models/nnmodel.py | 123 | INFO | Uni-Mol(QSAR) | fold 4, result {'auc': 0.8307712350182386, 'auroc': 0.8307712350182386, 'auprc': 0.9198949608932291, 'log_loss': 0.5994093204788167, 'acc': 0.7194244604316546, 'f1_score': 0.8368200836820083, 'mcc': -0.05221455345476955, 'precision': 0.7246376811594203, 'recall': 0.9900990099009901, 'cohen_kappa': -0.014218896164639672, 'f1_bst': 0.8368200836820083, 'acc_bst': 0.7194244604316546}
2023-06-14 03:00:13 | unimol/models/nnmodel.py | 135 | INFO | Uni-Mol(QSAR) | Uni-Mol metrics score: 
{'auc': 0.8398743016759775, 'auroc': 0.8398743016759775, 'auprc': 0.9375575268565082, 'log_loss': 0.46505588029267453, 'acc': 0.7954220314735336, 'f1_score': 0.8737864077669902, 'mcc': 0.3889369122641239, 'precision': 0.8075040783034257, 'recall': 0.9519230769230769, 'cohen_kappa': 0.3528071118247683, 'f1_bst': 0.8737864077669902, 'acc_bst': 0.7954220314735336}
2023-06-14 03:00:13 | unimol/models/nnmodel.py | 136 | INFO | Uni-Mol(QSAR) | Uni-Mol & Metric result saved!
2023-06-14 03:00:13 | unimol/utils/metrics.py | 288 | INFO | Uni-Mol(QSAR) | metrics for threshold: accuracy_score
2023-06-14 03:00:13 | unimol/utils/metrics.py | 301 | INFO | Uni-Mol(QSAR) | best threshold: 0.3723433135371459, metrics: 0.8054363376251789
learning_rate:  0.001
交叉验证结果: 0.8398743016759775
代码
文本
[11]
# 可视化不同learning rate训练出模型的AUC
import matplotlib.pyplot as plt

plt.figure(figsize=(8, 6)) # 设置图像大小
plt.style.use('seaborn-darkgrid') # 改变图的样式
plt.plot(lr_ft, auc_ft, 'o-', color='blue', linewidth=2, markersize=8, label='AUC vs Learning Rate') # 设置线型、线宽、颜色、点大小和图例
plt.xlabel("Learning rate", fontsize=14) # 设置x轴标签和字体大小
plt.ylabel("AUC", fontsize=14) # 设置y轴标签和字体大小
plt.title("AUC with Different Learning Rates", fontsize=16) # 设置标题和字体大小
plt.legend(loc='lower left', fontsize=12) # 显示图例,设置位置和字体大小
plt.show()

代码
文本

根据我们的微调参数,选取最佳交叉验证结果的模型(learning rate=0.0001)
如果追求更好的结果可以在最优学习率附近再进行微调

代码
文本

Step4: 测试“最优模型”

到这里,我们已经初步通过fine-tuning选出了较好的参数.那么为了检测我们模型的性能,我们需要引入测试集来测试.为了更好的区分数据集的三个部分,我们需要了解为什么要将数据分组: . 在机器学习和数据分析中,我们通常将数据集分为三个部分:训练集(Training Set)、验证集(Validation Set)和测试集(Test Set)。这三个集合各自的用途如下:

  1. 训练集(Training Set):这部分数据用于训练模型,包括参数的学习和模型的拟合。模型通过学习训练集中的数据和标签,调整其参数,以最小化预测和实际结果之间的误差。
  2. 验证集(Validation Set):验证集用于在训练过程中评估模型的性能,例如调整模型的超参数(如学习率、网络结构等),并进行模型选择。例如,如果我们有几种不同的模型(或者是同一种模型的不同配置),我们可以使用验证集来看哪一种模型的性能最好。这部分数据在训练过程中是不参与参数更新的,它只是用来对当前模型的性能做一个“中立”的评估。
  3. 测试集(Test Set):在模型训练和验证完毕后,我们会使用测试集来评估模型的性能。测试集应该是模型在训练过程中完全未见过的数据,用于提供对模型在未知数据上性能的无偏估计。测试集的表现可以视为模型在实际部署后的预期表现。

这种划分方法的主要目的是防止过拟合(Overfitting),即模型过于复杂,以至于在训练集上表现良好,但在未知数据(如测试集)上表现不佳。通过在训练和验证过程中使用不同的数据集,我们可以确保模型能够更好地泛化到新的、未见过的数据上。

代码
文本
[12]
clf = MolPredict(load_model='./learning_rate_0.0001') # 训练好的模型路径
代码
文本

MolPredict预测参数说明,预测部分第一步是载入训练好的模型,第二步是进行预测;

  • load_model:训练好的模型路径;
代码
文本
[6]
# 可以通过config查看载入的模型具体信息,也可以在路径下面查看对应的config.yaml文件
# clf.config
代码
文本
[13]
# 基于SMILES的文件输入模式的预测
test_pred = clf.predict('UniMolDemoBBBP/BBBP_test.csv') # 测试集数据
2023-06-14 03:04:24 | unimol/data/conformer.py | 56 | INFO | Uni-Mol(QSAR) | Start generating conformers...
229it [00:08, 25.52it/s]
2023-06-14 03:04:33 | unimol/data/conformer.py | 60 | INFO | Uni-Mol(QSAR) | Failed to generate conformers for 0.00% of molecules.
2023-06-14 03:04:33 | unimol/data/conformer.py | 62 | INFO | Uni-Mol(QSAR) | Failed to generate 3d conformers for 0.44% of molecules.
2023-06-14 03:04:34 | unimol/models/unimol.py | 107 | INFO | Uni-Mol(QSAR) | Loading pretrained weights from /opt/conda/lib/python3.8/site-packages/unimol-0.0.2-py3.8.egg/unimol/weights/mol_pre_all_h_220816.pt
2023-06-14 03:04:34 | unimol/models/nnmodel.py | 145 | INFO | Uni-Mol(QSAR) | start predict NNModel:unimolv1
2023-06-14 03:04:34 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 03:04:35 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 03:04:35 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 03:04:36 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 03:04:36 | unimol/tasks/trainer.py | 197 | INFO | Uni-Mol(QSAR) | load model success!
2023-06-14 03:04:36 | unimol/predict.py | 66 | INFO | Uni-Mol(QSAR) | final predict metrics score: 
{'auc': 0.8889454915944983, 'auroc': 0.8889454915944983, 'auprc': 0.9169517538679194, 'log_loss': 0.4587078287538678, 'acc': 0.8253275109170306, 'f1_score': 0.8757763975155279, 'mcc': 0.5984421633982058, 'precision': 0.8245614035087719, 'recall': 0.9337748344370861, 'cohen_kappa': 0.5854453294713975, 'f1_bst': 0.8757763975155279, 'acc_bst': 0.8253275109170306}
代码
文本

输出中所含的指标表示了学习率为0.0001训练出的模型在测试集上的表现(AUC: 0.8859)

第一个案例到这里就结束啦,感兴趣的同学可以通过微调其他参数(如epoch,batchsize)来得到更好的模型,或使用已有的模型进行分子BBBP的预测

代码
文本
Tutorial
Machine Learning
中文
notebook
Uni-Mol
QSAR
TutorialMachine Learning中文notebookUni-MolQSAR
已赞9
本文被以下合集收录
unimol
aki
更新于 2024-01-29
3 篇2 人关注
123
effort
更新于 2024-08-19
1 篇0 人关注
推荐阅读
公开
Uni-Mol性质预测实战-回归任务-电解液分子的介电常数
TutorialMachine Learning中文notebookUni-MolQSAR
TutorialMachine Learning中文notebookUni-MolQSAR
zhengh@dp.tech
发布于 2023-06-12
5 赞21 转存文件
公开
AI4S-Cup学习赛:小分子药物血脑屏障(BBB)渗透性分类预测 - Uni-Mol Baseline
AI4S Cup-Getting Started
AI4S Cup-Getting Started
hyb
发布于 2024-02-01
1 赞6 转存文件