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'm trying to reduce the memory consumption of a process using onnxruntime InferenceSession. To achieve this, I call InferenceSession.run with memory.enable_memory_arena_shrinkage, but it doesn't seem to have any effect. How do I do this in python?
Memory before model's creation = 98.734375
Memory in the beginning = 104.390625
Memory before shrinkage = 104.46875
Memory after shrinkage = 104.46875
Memory before shrinkage = 104.859375
Memory after shrinkage = 104.859375
Memory before shrinkage = 104.859375
Memory after shrinkage = 104.859375
Memory before shrinkage = 104.90625
Memory after shrinkage = 104.90625
Memory before shrinkage = 104.9375
Memory after shrinkage = 104.9375
Memory before shrinkage = 104.953125
Memory after shrinkage = 104.953125
Memory before shrinkage = 104.953125
Memory after shrinkage = 104.953125
Memory before shrinkage = 104.984375
Memory after shrinkage = 104.984375
Memory before shrinkage = 105.109375
Memory after shrinkage = 105.109375
Memory before shrinkage = 105.125
Memory after shrinkage = 105.125
Memory in the end = 105.140625
Urgency
No response
Platform
Linux
OS Version
Ubuntu 20.04.6 LTS
ONNX Runtime Installation
Released Package
ONNX Runtime Version or Commit ID
1.20.1
ONNX Runtime API
Python
Architecture
X64
Execution Provider
Default CPU
Execution Provider Library Version
No response
The text was updated successfully, but these errors were encountered:
This feature was primarily introduced for GPU memory.
For CPU we recommend disabling the arena all together and see if default allocator does a better job (it often does).
Describe the issue
I'm trying to reduce the memory consumption of a process using onnxruntime InferenceSession. To achieve this, I call InferenceSession.run with memory.enable_memory_arena_shrinkage, but it doesn't seem to have any effect. How do I do this in python?
To reproduce
This code produce the following output:
Urgency
No response
Platform
Linux
OS Version
Ubuntu 20.04.6 LTS
ONNX Runtime Installation
Released Package
ONNX Runtime Version or Commit ID
1.20.1
ONNX Runtime API
Python
Architecture
X64
Execution Provider
Default CPU
Execution Provider Library Version
No response
The text was updated successfully, but these errors were encountered: