Fictionarry / ER-NeRF

[ICCV'23] Efficient Region-Aware Neural Radiance Fields for High-Fidelity Talking Portrait Synthesis
https://fictionarry.github.io/ER-NeRF/
MIT License
1.02k stars 133 forks source link

ValueError: Found array with 0 sample(s) (shape=(0, 2)) while a minimum of 1 is required by NearestNeighbors. #146

Closed G-force78 closed 4 months ago

G-force78 commented 4 months ago

Traceback (most recent call last): File "/content/ER-NeRF/data_utils/process.py", line 388, in extract_background(base_dir, ori_imgs_dir) File "/content/ER-NeRF/data_utils/process.py", line 86, in extract_background nbrs = NearestNeighbors(n_neighbors=1, algorithm='kd_tree').fit(fg_xys) File "/usr/local/lib/python3.10/dist-packages/sklearn/neighbors/_unsupervised.py", line 176, in fit return self._fit(X) File "/usr/local/lib/python3.10/dist-packages/sklearn/neighbors/_base.py", line 491, in _fit X = self._validate_data(X, accept_sparse="csr", order="C") File "/usr/local/lib/python3.10/dist-packages/sklearn/base.py", line 565, in _validate_data X = check_array(X, input_name="X", **check_params) File "/usr/local/lib/python3.10/dist-packages/sklearn/utils/validation.py", line 931, in check_array raise ValueError( ValueError: Found array with 0 sample(s) (shape=(0, 2)) while a minimum of 1 is required by NearestNeighbors.

G-force78 commented 4 months ago

Had frames with no person in the video