Relphormer baseline
This commit is contained in:
		
							
								
								
									
										19
									
								
								scripts/fb15k-237/fb15k-237.sh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								scripts/fb15k-237/fb15k-237.sh
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,19 @@
 | 
			
		||||
nohup python -u main.py --gpus "1" --max_epochs=16  --num_workers=32 \
 | 
			
		||||
   --model_name_or_path  bert-base-uncased \
 | 
			
		||||
   --accumulate_grad_batches 1 \
 | 
			
		||||
   --model_class BertKGC \
 | 
			
		||||
   --batch_size 64 \
 | 
			
		||||
   --checkpoint /kg_374/Relphormer/pretrain/output/FB15k-237/epoch=15-step=19299-Eval/hits10=0.96.ckpt \
 | 
			
		||||
   --pretrain 0 \
 | 
			
		||||
   --bce 0 \
 | 
			
		||||
   --check_val_every_n_epoch 1 \
 | 
			
		||||
   --overwrite_cache \
 | 
			
		||||
   --data_dir dataset/FB15k-237 \
 | 
			
		||||
   --eval_batch_size 128 \
 | 
			
		||||
   --max_seq_length 128 \
 | 
			
		||||
   --lr 3e-5 \
 | 
			
		||||
   --max_triplet 64 \
 | 
			
		||||
   --add_attn_bias True \
 | 
			
		||||
   --use_global_node True \
 | 
			
		||||
   >logs/train_fb15k-237.log 2>&1 &
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										14
									
								
								scripts/umls/pretrain_umls.sh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								scripts/umls/pretrain_umls.sh
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,14 @@
 | 
			
		||||
nohup python -u main.py --gpus "0," --max_epochs=20  --num_workers=32 \
 | 
			
		||||
   --model_name_or_path  bert-base-uncased \
 | 
			
		||||
   --accumulate_grad_batches 1 \
 | 
			
		||||
   --model_class BertKGC \
 | 
			
		||||
   --batch_size 128 \
 | 
			
		||||
   --pretrain 1 \
 | 
			
		||||
   --bce 0 \
 | 
			
		||||
   --check_val_every_n_epoch 1 \
 | 
			
		||||
   --overwrite_cache \
 | 
			
		||||
   --data_dir xxx/Relphormer/dataset/umls \
 | 
			
		||||
   --eval_batch_size 256 \
 | 
			
		||||
   --max_seq_length 64 \
 | 
			
		||||
   --lr 1e-4 \
 | 
			
		||||
   >logs/pretrain_umls.log 2>&1 &
 | 
			
		||||
							
								
								
									
										19
									
								
								scripts/umls/umls.sh
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										19
									
								
								scripts/umls/umls.sh
									
									
									
									
									
										Executable file
									
								
							@@ -0,0 +1,19 @@
 | 
			
		||||
nohup python -u main.py --gpus "0," --max_epochs=20  --num_workers=32 \
 | 
			
		||||
   --model_name_or_path  bert-base-uncased \
 | 
			
		||||
   --accumulate_grad_batches 1 \
 | 
			
		||||
   --model_class BertKGC \
 | 
			
		||||
   --batch_size 128 \
 | 
			
		||||
   --checkpoint /where/you/put/the/checkpoint/file/of/the/pretrain/process \
 | 
			
		||||
   --pretrain 0 \
 | 
			
		||||
   --bce 0 \
 | 
			
		||||
   --check_val_every_n_epoch 1 \
 | 
			
		||||
   --overwrite_cache \
 | 
			
		||||
   --data_dir dataset/umls \
 | 
			
		||||
   --eval_batch_size 256 \
 | 
			
		||||
   --max_seq_length 128 \
 | 
			
		||||
   --lr 3e-5 \
 | 
			
		||||
   --max_triplet 64 \
 | 
			
		||||
   --add_attn_bias True \
 | 
			
		||||
   --use_global_node True \
 | 
			
		||||
   >logs/train_umls.log 2>&1 &
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										19
									
								
								scripts/wn18rr/wn18rr.sh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								scripts/wn18rr/wn18rr.sh
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,19 @@
 | 
			
		||||
nohup python -u main.py --gpus "0," --max_epochs=20  --num_workers=32 \
 | 
			
		||||
   --model_name_or_path  bert-base-uncased \
 | 
			
		||||
   --accumulate_grad_batches 1 \
 | 
			
		||||
   --model_class BertKGC \
 | 
			
		||||
   --batch_size 128 \
 | 
			
		||||
   --checkpoint /where/you/put/the/checkpoint/file/of/the/pretrain/process \
 | 
			
		||||
   --pretrain 0 \
 | 
			
		||||
   --bce 0 \
 | 
			
		||||
   --check_val_every_n_epoch 1 \
 | 
			
		||||
   --overwrite_cache \
 | 
			
		||||
   --data_dir dataset/WN18RR \
 | 
			
		||||
   --eval_batch_size 256 \
 | 
			
		||||
   --max_seq_length 128 \
 | 
			
		||||
   --lr 3e-5 \
 | 
			
		||||
   --max_triplet 32 \
 | 
			
		||||
   --add_attn_bias True \
 | 
			
		||||
   --use_global_node True \
 | 
			
		||||
   >logs/train_wn18rr.log 2>&1 &
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user