Skip to content

Issue with the initialization in the ADMM Optimizer #655

@Tzortzinaprk

Description

@Tzortzinaprk

Hello, I’m new in programming and I’m currently doing my master thesis and it is in Python. I'm using the ADMM Optimizer from the qiskit library. My goal is to reconstruct the measurements that I have been given and take the reconstructed image. For this reason I'm trying to minimize this function:

Image

where the second part is the total variation. Unfortunately, my A matrix is too big (50408, 6859), while b is (50408,). In addition, the matrixes contain complex values, so they have a real and an imaginary part. Through the optimizer, I'm trying to find the x matrix. I initialized the parameters and wrote the objective function as can be seen below :

x_vars = [mdl.continuous_var(name=f"x{i}", lb=0) for i in range(S.shape[1])]

lambda_tv = 0.5
TV = mdl.sum((x_vars[i + 1] - x_vars[i]) ** 2 for i in range(S.shape[1] - 1))

objective = mdl.sum(
(mdl.sum(S[i, j] * x_vars[j] for j in range(S.shape[1])) - u[i]) ** 2 for i in range(S.shape[0])
) + lambda_tv * TV

The program runs but it never stops. I don't get any bug and the model never gets to the ADMM optimizer.
I've tried using equations from the numpy library, but they are not compatible. What should I do in order to overcome this problem?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions