fix inference bug

This commit is contained in:
xinjun ma 2021-09-11 16:22:12 +08:00
parent 3c8b0c7812
commit 9d4ba28486
2 changed files with 2 additions and 2 deletions

View File

@ -27,6 +27,6 @@ fi
DATA_PATH=$1
GPU_ID=$2
python -u validate.py --root_dir "${DATA_PATH}/dataset_low_res" --dataset_name blendedmvs --save_visual --img_wh 768 576 --n_views ${VIEW_NUM} --n_depths 32 16 8 --interval_ratios 4.0 2.0 1.0 --levels 3 --split val --gpu_id ${GPU_ID} > log.txt 2>&1 &
CUDA_VISIBLE_DEVICES=${GPU_ID} python -u validate.py --root_dir "${DATA_PATH}/dataset_low_res" --dataset_name blendedmvs --img_wh 768 576 --n_views ${VIEW_NUM} --n_depths 32 16 8 --interval_ratios 4.0 2.0 1.0 --levels 3 --split val > log.txt 2>&1 &
cd ..

View File

@ -432,5 +432,5 @@ def groupwise_correlation(v1, v2, groups, dim):
reshaped_size = (n, d, h, w, groups, c // groups)
v1_reshaped = v1.view(*reshaped_size)
v2_reshaped = v2.view(*reshaped_size)
vc = P.ReduceSum()(v1_reshaped * v2_reshaped, dim + 1)
vc = P.Transpose()(P.ReduceSum()(v1_reshaped * v2_reshaped, 5), (0, 4, 1, 2, 3))
return vc