Slimnios / SaGess

SaGess denoising diffusion model
3 stars 1 forks source link

RuntimeError: probability tensor contains either `inf`, `nan` or element < 0 #7

Open CalmaQi opened 1 day ago

CalmaQi commented 1 day ago
diffusion_model_discrete.py", line 158, in validation_step
    noisy_data = self.apply_noise(dense_data.X, dense_data.E, data.y, node_mask)
    SaGess/src/diffusion_model_discrete.py", line 422, in apply_noise
    sampled_t = diffusion_utils.sample_discrete_features(probX=probX, probE=probE, node_mask=node_mask)
    /SaGess/src/diffusion/diffusion_utils.py", line 264, in sample_discrete_features
    E_t = probE.multinomial(1).reshape(node_mask.size(0), node_mask.size(1), node_mask.size(1))   # (bs, n, n)
RuntimeError: probability tensor contains either `inf`, `nan` or element < 0
CalmaQi commented 1 day ago

Great job, but I'm wondering why this error occurred. Could you help me resolve it?