We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Old LuxBlend code:
# Memory usage (only available for OpenCL engines) if str.endswith(engine, 'OCL') and rendering_controls.stats_memory: device_stats = stats.Get("stats.renderengine.devices") max_memory = float('inf') used_memory = 0 for i in range(device_stats.GetSize()): device_name = device_stats.GetString(i) # Max memory available is limited by the device with least amount of memory device_max_memory = stats.Get("stats.renderengine.devices." + device_name + ".memory.total").GetFloat() device_max_memory = int(device_max_memory / (1024 * 1024)) if device_max_memory < max_memory: max_memory = device_max_memory device_used_memory = stats.Get("stats.renderengine.devices." + device_name + ".memory.used").GetFloat() device_used_memory = int(device_used_memory / (1024 * 1024)) if device_used_memory > used_memory: used_memory = device_used_memory if used_memory > self.mem_peak: self.mem_peak = used_memory stats_list.append('Memory: %d MB/%d MB' % (used_memory, max_memory))
When implementing this, check if stats.renderengine.devices really only returns the enabled devices (important for max. available memory calculation).
stats.renderengine.devices
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Old LuxBlend code:
When implementing this, check if
stats.renderengine.devices
really only returns the enabled devices (important for max. available memory calculation).The text was updated successfully, but these errors were encountered: