You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am getting the following error of spawning the process while running "python image_retrieval.py"
Brief error message: RuntimeError:
An attempt has been made to start a new process before the
current process has finished its bootstrapping phase.
This probably means that you are not using fork to start your
child processes and you have forgotten to use the proper idiom
in the main module:
if name == 'main':
freeze_support()
Same error here. maybe the file image_retrieval.py be wrapped in a main() function and then end with:
if name == "main":
main()
edit:
yep, did just that and it works, as in:
import os
import numpy as np
import tensorflow as tf
from sklearn.neighbors import NearestNeighbors
from src.CV_IO_utils import read_imgs_dir
from src.CV_transform_utils import apply_transformer
from src.CV_transform_utils import resize_img, normalize_img
from src.CV_plot_utils import plot_query_retrieval, plot_tsne, plot_reconstructions
from src.autoencoder import AutoEncoder
if name == 'main':
# Run mode: (autoencoder -> simpleAE, convAE) or (transfer learning -> vgg19)
modelName = "vgg19" # try: "simpleAE", "convAE", "vgg19"
trainModel = True
parallel = True # use multicore processing
...
..._
I am getting the following error of spawning the process while running "python image_retrieval.py"
Brief error message:
RuntimeError:
An attempt has been made to start a new process before the
current process has finished its bootstrapping phase.
This probably means that you are not using fork to start your
child processes and you have forgotten to use the proper idiom
in the main module:
if name == 'main':
freeze_support()
error.txt
Can anyone plz help me saying why I am getting this error and how to get rid of this error?
The text was updated successfully, but these errors were encountered: