Skip to content

Huge mem leak #6

@sschuldenzucker

Description

@sschuldenzucker

I noticed a memory leak that occurs when you solve many independent LPs in a row.

Reproduce:

Simply run (say) the first example from the web site 10.000 times (and kill it before your ram isexhausted and your system becomes unresponsive):

import numpy as np
from pycpx import CPlexModel

for i in range(10000):
    A = np.array([[1,0,0], [1,1,0], [1,1,1]])
    b = np.array([1,2,3])

    m = CPlexModel()

    x = m.new(3)
    t = m.new()

    m.constrain( abs((A*x - b)) <= t)
    m.minimize(t)

I'm on pycpx 0.3 and cplex 12.6.1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions