seunghan96 / softclt

52 stars 5 forks source link

Dataset and Code Error #3

Open good-demo opened 3 months ago

good-demo commented 3 months ago

Thank you for sharing your work,i am currently facing issues with the dataset About SoftCLT + TS2Vec Semi-supervised Classification The data preparation was not specified,is there a relevant script to handle this segmented data?

Transfer Learning Source dataset: SleepEEG this data preparation was also not specified

good-demo commented 3 months ago

Use SleepEDF as Source dataset Traceback (most recent call last): File "main_pretrain_TL.py", line 102, in Trainer_wo_DTW_wo_val(args, model, temporal_contr_model, model_optimizer, File "/mnt/share/yxd/softclt-main/softclt_catcc/trainer/trainer.py", line 228, in Trainer_wo_DTW_wo_val train_loss, train_acc = model_train_wo_DTW(dist_func, args.dist, args.tau_inst, model, temporal_contr_model, model_optimizer, temp_cont_optimizer, File "/mnt/share/yxd/softclt-main/softclt_catcc/trainer/train_utils.py", line 123, in model_train_woDTW , _, features1, features2, final_loss = model(aug1, aug2, dist_mat_batch) File "/mnt/share/yxd/envs/order/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl return forward_call(*args, *kwargs) File "/mnt/share/yxd/softclt-main/softclt_catcc/models/model.py", line 63, in forward temporalloss += (1-self.lambda) temp_CL_soft(aug1, aug2, timelag_L, timelag_R) File "/mnt/share/yxd/softclt-main/softclt_catcc/models/soft_losses.py", line 47, in temp_CL_soft loss = torch.sum(logits[:,t]*timelag_L) RuntimeError: The size of tensor a (63) must match the size of tensor b (3001) at non-singleton dimension 2

good-demo commented 3 months ago

Is it due to incorrect data or code errors