<class 'ValueError'> Found array with 0 sample(s) (shape=(0, 2)) while a minimum of 1 is required.
D:\anaconda3\python.exe D:\work\GeneFacePlusPlus-main\data_gen\utils\process_video\extract_segment_imgs.py todo videos number: 1 INFO: Created TensorFlow Lite XNNPACK delegate for CPU. generating segment images in single-process...: 0%| | 0/100 [00:00<?, ?it/s]| Extracting Segmaps && Saving... generating segment images in single-process...: 100%|██████████| 100/100 [00:16<00:00, 6.20it/s] | Extracted Segmaps Done. | Extracting background... combining backgrounds...: 100%|██████████| 5/5 [00:01<00:00, 3.63it/s] Traceback (most recent call last): File "D:\work\GeneFacePlusPlus-main\data_gen\utils\process_video\extract_segment_imgs.py", line 363, in extract_segment_job bg_img = extract_background(img_lst, segmap_mask_lst, method=background_method, device=device, mix_bg=mix_bg) File "D:\work\GeneFacePlusPlus-main\data_gen\utils\process_video\extract_segment_imgs.py", line 139, in extract_background nbrs = NearestNeighbors(n_neighbors=1, algorithm='kd_tree').fit(fg_xys) File "D:\anaconda3\lib\site-packages\sklearn\neighbors_unsupervised.py", line 166, in fit return self._fit(X) File "D:\anaconda3\lib\site-packages\sklearn\neighbors_base.py", line 435, in _fit X = self._validate_data(X, accept_sparse="csr") File "D:\anaconda3\lib\site-packages\sklearn\base.py", line 566, in _validate_data X = check_array(X, **check_params) File "D:\anaconda3\lib\site-packages\sklearn\utils\validation.py", line 805, in check_array raise ValueError( ValueError: Found array with 0 sample(s) (shape=(0, 2)) while a minimum of 1 is required.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\work\GeneFacePlusPlus-main\data_gen\utils\process_video\extract_segment_imgs.py", line 493, in
i I also encountered the same problem. Have you solved it?
You should check every ”replace“ like this:
Because there are differences in paths between Windows and Linux systems, '\' and'/'.
Just print the paths and check.
Still have this problem. Its stops at 27%. Did you find any solution for that?
i I also encountered the same problem. Have you solved it?