Comments (4)
Hi,
I agree that there can be a memory leak if you repeatedly delete and re instantiate the multithreaded augmenter. The pin_memory feature is experimental and I added it only last week. I will try to get this fixed as soon as possible. Until then, don't reinstantiate it or use pin_memory=False.
Following the way pytorch does this is very complicated (and a lot of work to integrate into our code) and I think we can try to get it running easier somehow. If you have ideas, please let me know =)
Thanks for pointing this out!
Best,
Fabian
from batchgenerators.
All workers and the pin memory thread now use an abort_event (multiprocessing.Event) and will exit if it was set. This event can be set from various places, such as crashing workers (which would previously have resulted in the main process waiting for new data indefinitely), crashing other things or calling the destructor of MultiThreadedAugmenter. Please test and see if you still experience memory leaks. If you do, please provide a minimalistic example and I will figure out a way to solve this.
Best,
Fabian
from batchgenerators.
Works perfectly now! Thanks for the quick fix!
from batchgenerators.
No worries, it's always good to get user feedback =) Thanks a lot again for pointing out the issue
from batchgenerators.
Related Issues (20)
- Suggestion of multiprocess mechanism in MultiThreadedAugmenter
- How can we use batchgenerators offline
- Data type for both input images and labels
- How to do batchgenerator on many images in a folder?
- Why twice crop in Brats example?
- Proposal: reproducibility in DataLoader HOT 1
- Incompatible with nnU-Net? HOT 1
- ImportError: cannot import name 'MultiThreadedAugmenter' from 'batchgenerators.dataloading' HOT 2
- RuntimeError HOT 7
- fillup_pad disappeared?
- from batchgenerators.dataloading import SingleThreadedAugmenter?
- RuntimeWarning in color_augumentations.
- error HOT 1
- Error Importing SlimDataLoaderBase HOT 3
- MultiThreadedAugmenter issues HOT 4
- multithreaded_with_batches.ipynb: ImportError HOT 1
- A problem about SpatialTransform_2
- About 3D augmentation
- Question about multithreading:
- ImportError: cannot import name 'MultiThreadedAugmenter' from 'batchgenerators.dataloading' HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from batchgenerators.