It depends on what you're doing. Some ideas:
- Get a new GPU with more memory
- Use a smaller model
- If your model accepts a variable input size, use a smaller input
- For object detectors, reduce the number of patches per image
- Run on the CPU
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!