Pardiso.jl icon indicating copy to clipboard operation
Pardiso.jl copied to clipboard

Adaptations for Pardiso 7.2

Open j-fu opened this issue 4 years ago • 8 comments

Hi, trying to add support for Pardiso7 here. AFAIK, it has no breaking API changes wrt. 6.x.

However runtests bailed out in the indefinite hermitian case as Pardiso doesn't report an error in this case. Nevetheless, it does not solve, so I compare hashes of X in order to catch this case. May be this is not the smartest way, but works.

Will discuss this with upstream.

j-fu avatar Apr 09 '21 09:04 j-fu

However runtests bailed out in the indefinite hermitian case as Pardiso doesn't report an error in this case.

Is there no error code at all or something else that can be inspect for this?

KristofferC avatar Apr 09 '21 09:04 KristofferC

Just contacted upstream wrt to this. I assume it is a bug in Pardiso (I checked: Err[] is zero), as it knows to do nothing in this case. EDIT: We may wait for a response...

j-fu avatar Apr 09 '21 09:04 j-fu

The PR hashes X before and after, and figures this out (so runtests works with on my system), but this is not optimal.

j-fu avatar Apr 09 '21 09:04 j-fu

Hi, I contacted upstream, contact was acknowledged, but I did not get a response so far, they must be really busy. I propose to move on with the PR and keep the hashing hack in order to get Pardiso7 functionality, the more that new users won't be able to get Pardiso6 anymore.

  • IMHO the hashing hack is reasonably fast (anyway, issymmetric is called etc.) and reliable
  • Extrapolating from their release policy I would assume that fixes will be provided in a new release which may be linked with some other features.

Once the fix is in, the hashing hack is easily removed.

j-fu avatar Apr 22 '21 14:04 j-fu

Seems upstream dialed back the current version to Pardiso6, so we can keep this PR on hold so far.

j-fu avatar Jun 23 '21 20:06 j-fu

Seems upstream dialed back the current version to Pardiso6,

What is upstream here?

KristofferC avatar Jul 02 '21 12:07 KristofferC

The guys at pardiso-project.org I am in contact with (Olaf Schenk).

I the moment, licensing and download at pardiso-project.org provide 6.0 instead of 7.2.

j-fu avatar Jul 02 '21 14:07 j-fu

Alright!

KristofferC avatar Jul 02 '21 14:07 KristofferC

Pardiso8 is out, now provided by a new startup, Panua. They now provide 12 month user and machine locked academic licenses and verify academic affiliation. The problem with the hermitian indefinite case persists, I contacted Olaf Schenk on this.

j-fu avatar May 20 '23 00:05 j-fu

@j-fu Do you know if this code works for Pardiso8?

mipals avatar Jan 25 '24 14:01 mipals

I didn't test this yet, will try to find time.

j-fu avatar Jan 25 '24 14:01 j-fu

Ok got the version from panua: libpanuapardiso-20230908-linux.so . Tests for Float64/Complex64 work for unsymmetric, hermitian posdef. Tests fail for hermitian indef and symmetric. Didn't check deeper.

I guess for installation now we would tell users: "rename libpanuapardiso-YYYYMMDD-linux.so to libpanuapardiso.so", or is there any way to pass parameters to "deps/build.jl" ? EDIT: Probably an environment variable...

j-fu avatar Jan 26 '24 16:01 j-fu

Panua changed license conditions:

Full academic licence
Unlimited number of cores.
Renewable.
Only for academic users.
Tied to a single user & node.
Duration: 365 days
Price: 300.00 CHF
Free academic licence
Limited to 2 cores.
Renewable.
Only for academic users.
Tied to a single user & node.
Duration: 30 days
Price: Free
Obtain academic trial licence

j-fu avatar Jan 26 '24 16:01 j-fu

Full academic cluster licence
Unlimited number of cores.
Unlimited number of nodes.
Only for academic users.
Limited to a single user & cluster.
Duration: 365 days
Price: 1200.00 CHF

j-fu avatar Jan 26 '24 16:01 j-fu

Thanks a lot for checking it out Jürgen. A shame that the free license only covers two cores 😑

mipals avatar Jan 28 '24 15:01 mipals

Hi again, now I've gotten Pardiso 8 to work on apple silicon. However, as you mentioned Jürgen the test fail for hermitian indef and symmetric. I think that there might be a problem with the try-catch for Hermitian matrices in the solve function.

mipals avatar Feb 07 '24 12:02 mipals

I am not in academia anymore so I can't really get a license and test things out. If anyone wants to take over maintenance for this package write here and I will give you commit access.

KristofferC avatar Feb 07 '24 13:02 KristofferC

I am not in academia anymore so I can't really get a license and test things out. If anyone wants to take over maintenance for this package write here and I will give you commit access.

... thinking about it ... I am in academia, and also aquainted with two of the main authors of Pardiso.

j-fu avatar Feb 08 '24 22:02 j-fu

I've invited you as a collaborator to the repo.

KristofferC avatar Feb 09 '24 09:02 KristofferC

I will be in academia for at least one more year and would like to use this package meanwhile. Would be happy to help with the maintenance for now, but I am pretty inexperienced when it comes to contributing to open-source. So maybe it is enough with just Jürgen?

mipals avatar Feb 09 '24 09:02 mipals

I added you as well so you can keep an eye on each other ;)

KristofferC avatar Feb 09 '24 09:02 KristofferC

Haha, thanks @KristofferC , sounds like a good idea 👀

@j-fu I saw in the email from Olaf that he was asking for some Julia code that reproduces the issue. Will you send him some? If not I would be happy to do it.

mipals avatar Feb 09 '24 13:02 mipals

I first wanted to rename and update this PR and try this out with Panua Pardiso (had it running already), as I ran out of pardiso8 license. If you have something ready immediately, please feel free to send it to Olaf. It feels the issue is the same since the opening of this PR (though I had no time to look more deeply into this): pardiso returns without solving and without indicating an error if it doesn't recognize the matrix type.

j-fu avatar Feb 09 '24 13:02 j-fu

I have a working license already. I will send Olaf an example.

I agree that that the current issue is most likely the same issue that was at as for 7.2, i.e. that Pardiso does not return an error when it should.

mipals avatar Feb 09 '24 14:02 mipals

Codecov Report

Attention: Patch coverage is 0% with 3 lines in your changes are missing coverage. Please review.

Project coverage is 40.56%. Comparing base (b64c486) to head (fbaec50).

Files Patch % Lines
src/project_pardiso.jl 0.00% 2 Missing :warning:
src/Pardiso.jl 0.00% 1 Missing :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##           master      #75      +/-   ##
==========================================
- Coverage   40.67%   40.56%   -0.11%     
==========================================
  Files           4        4              
  Lines         386      387       +1     
==========================================
  Hits          157      157              
- Misses        229      230       +1     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Feb 09 '24 18:02 codecov[bot]

Do we have any way to redistribute as a JLL as we do for MKL? I suspect not from a cursory look at their website. I am also getting an academic license and can help with maintenance.

rayegun avatar Feb 09 '24 18:02 rayegun

That of course would make things more robust, however there would still be the question of a license in sync with the version in the JLL. AFAIK, newly obtained licenses would not work with with older pardiso versions.

j-fu avatar Feb 09 '24 18:02 j-fu

Ah it looks like the free licenses expire within 30 days, I'm not sure they're going to agree to redistribution in light of that

rayegun avatar Feb 09 '24 18:02 rayegun

Just a quick update: I've just helped Dimosthenis from Panua testing out a new binary. It seems like they have now fixed the issue on their end i.e. Panua-Pardiso now return the correct error code.

mipals avatar Feb 27 '24 10:02 mipals

So they will provide an update of their download then ?

j-fu avatar Feb 27 '24 11:02 j-fu