Skip to content

Memory Leak: RAM increase due to repeated FieldContainer.imshow() #833

@adtzlr

Description

@adtzlr

In an interactive session. It seems that the screenshot method, especially with nonlinear_subdivision > 1, eats the RAM. Unfortunately, we can't do much about it.

import felupe as fem

mesh = fem.Circle(n=12).add_midpoints_edges()
plotter = mesh.plot(off_screen=True)
img = plotter.screenshot()

import matplotlib.pyplot as plt

plt.imshow(img)

grafik

Even for such simple meshes and without nonlinear_subdivision > 1, only Restart Kernel helps to free the memory in an interactive Python session after multiple screenshot calls.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions