Hello.
I'm going to use the Python code to use multiprocessing Every time I created another process, I imported and initialized libraries separately, which slowed me down.
How can other processes share the parts that import and initialize functions?
Is there anyone who solved the related problem?
python
my_imports.Write py like this.
import example1, example2
__all__ = ['example1', 'example2']
Try this in another file, other_file.py~
from my_imports import *
print example1.~~~
It can be stated in this way
from my_imports import example1, example2
© 2024 OneMinuteCode. All rights reserved.