zhan-xu / RigNet

Code for SIGGRAPH 2020 paper "RigNet: Neural Rigging for Articulated Characters"
GNU General Public License v3.0
1.36k stars 189 forks source link

How to reduce/eliminate the "randomness" of the predicted skeleton? #72

Open kts707 opened 2 years ago

kts707 commented 2 years ago

Hi @zhan-xu

Thanks for the great work!

As discussed in #41, "randomness" mainly comes from random sampling. I tried to manually set a fixed seed before all the operations involving such random sampling. However, the randomness is still there...

I was wondering if there is any way to reduce/eliminate the result's randomness as my output differs by a lot in each run. Any suggestion/comment will be greatly appreciated!

CoolGua0113 commented 2 years ago

So far as I tried, setting numpy.random.seed() and seed in sample_points_poisson_disk() could help reproduce results. e.g. codes here: https://github.com/zhan-xu/RigNet/blob/master/geometric_proc/common_ops.py#L50 samples = mesh.sample_points_poisson_disk(number_of_points=4000, seed=123)

kts707 commented 2 years ago

Hi @CoolGua0113 ,

Thanks for your answer! I set the numpy seed and the seed in sample_points_poisson_disk(). However, I am still getting different results every time. Is there anything that you changed to get consistent results?

CoolGua0113 commented 2 years ago

Nothing else sorry...I could get completely same results each run after setting these two seeds. Maybe you could check the input to RigNet(in create_single_data()) first? As mentioned by the author, the randomness of the network might be less important.

kts707 commented 2 years ago

Did you set the numpy seed before every numpy operation that involves randomness?

I am basically running quick_start.py with numpy seed set before loading the network only, however, still getting different results in each run (the sample_points_poisson_disk() seed is also set to a deterministic number, and the input is also the same each time)