VITA-Group/FSGS

Pearson Correlation Loss in paper or code

Opened this issue · 4 comments

Hi, I found that the Pearson Correlation Loss of paper and code is inconsistent.
in paper:
Snipaste_2024-01-19_17-28-02
in code:

FSGS/train.py

Lines 105 to 108 in 8c2e181

depth_loss = min(
(1 - pearson_corrcoef( - midas_depth, rendered_depth)),
(1 - pearson_corrcoef(1 / (midas_depth + 200.), rendered_depth))
)

Yes it makes me confused.

I am also curious about this.

The author has answered this question in issues/1

Hi guys, I'm still confused.

  1. the inverse depth means if the real depths is 50m, the inverse depth will be 1/50; but why - midas_depth in the code?
  2. the equation in the paper is: Corr(D_ras, D_est), which is implemented by pearson_corrcoef. The pearson_corr_coef is the same as the eq in the paper.
    image
    but the code is 1 - pearson_corrcoef.
    cc @zehaozhu @henrypearce4D @zhiwenfan