Skip to content
New issue

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

cannot see ShapeVariationAnalyzer module #54

Closed
luciacev opened this issue Sep 11, 2020 · 11 comments · Fixed by commontk/CTK#943
Closed

cannot see ShapeVariationAnalyzer module #54

luciacev opened this issue Sep 11, 2020 · 11 comments · Fixed by commontk/CTK#943
Assignees

Comments

@luciacev
Copy link

@jcfr @allemangD @bpaniagua

Hi

ShapeVariationAnalyzer is not working/cannot find module after installing SlicerCMF. Thanks!

Screen Shot 2020-09-11 at 6 10 02 AM

@allemangD
Copy link

allemangD commented Sep 17, 2020

Per the log in DCBIA-OrthoLab/SlicerCMF#18, the issue seems to be that sklearn is not configured properly for Mac, and this causes errors when it is imported by shapepca, which is imported by ShapeVariationAnalysis. The same happens if only ShapeVariationAnalyzer is installed via the extension manager (without SlicerCMF).

Here is a full log from my machine (using yesterday's Slicer preview release) Slicer_29370_20200917_132211_450.log

When I build ShapeVariationAnalyzer myself, no such error occurs.

$ git clone https://github.com/DCBIA-OrthoLab/ShapeVariationAnalyzer.git
$ cd ShapeVariationAnalyzer
$ mkdir build
$ cd build
$ cmake -DShapeVariationAnalyzer_BUILD_SLICER_EXTENSION=ON -DSlicer_DIR=~/src/Slicer/build/Slicer-build ..
$ ninja
$ inner-build/SlicerWithShapeVariationAnalyzer

This tells me there may be some issue in the factory machine causing sklearn not to be configured correctly. @jcfr, do you have any thoughts on this?

If I understand the superbuild correctly, scikit-learn is installed via pip in the default configuration.

https://github.com/DCBIA-OrthoLab/ShapeVariationAnalyzer/blob/master/SuperBuild/External_python-ShapeVariationAnalyzer-requirements.cmake#L43-L54

If I manually install via pip with the same hashes, I get an error that the hash does not match:

ERROR: THESE PACKAGES DO NOT MATCH THE HASHES FROM THE REQUIREMENTS FILE. If you have updated the package versions, please update the hashes. Otherwise, examine the package contents carefully; someone may have tampered with them.
    scikit-learn==0.23.1 from https://files.pythonhosted.org/packages/ea/47/078b5ef83ccff1def48c29158be998375321397be53af6dc10f22c6dc08d/scikit_learn-0.23.1-cp38-cp38-macosx_10_9_x86_64.whl#sha256=0c3464e46ef8bd4f1bfa5c009648c6449412c8f7e9b3fc0c9e3d800139c48827 (from -r req.txt (line 1)):
        Expected sha256 e585682e37f2faa81ad6cd4472fff646bf2fd0542147bec93697a905db8e6bd2
        Expected     or 058d213092de4384710137af1300ed0ff030b8c40459a6c6f73c31ccd274cc39
        Expected     or e9879ba9e64ec3add41bf201e06034162f853652ef4849b361d73b0deb3153ad
             Got        0c3464e46ef8bd4f1bfa5c009648c6449412c8f7e9b3fc0c9e3d800139c48827

This is confusing to me, since the superbuild succeeds locally without issue and cdash does not report any such issue.

Edit: The pip commands above were run on Python 3.8, not 3.6, leading to the hash error.

@allemangD
Copy link

allemangD commented Sep 17, 2020

The issue doesn't seem to affect the Linux build of Slicer or the extension manager. Here is the log from my Ubuntu 20 machine after installing the SlicerCMF extension bundle. ShapeVariationAnalyzer and the Population Analysis module load without issue.
Slicer_29363_20200917_135032_863.log I don't have a Windows machine to test, but it seems this is a mac-specific issue.

@bpaniagua
Copy link

Do you mind testing in your macbook?

@allemangD
Copy link

The above logs are from my macbook. Everything works correctly if I build the extension myself, but loading from the extension manager causes the problem. This makes me think there is some issue with the factory machine.

In the second comment I was just noting that the issue is never present for me on linux, to emphasize I think this issue is specific to the mac factory machine and not the others, although I can't confirm for Windows.

@bpaniagua
Copy link

Thanks for checking, David!
@sjh26 can you please check in any issues in the macOS factory?

@jcfr
Copy link
Contributor

jcfr commented Nov 16, 2020

If I manually install via pip with the same hashes, I get an error that the hash does not match:

@allemangD and I looked at this, and python 3.6 (version also used in Slicer) need to be used to ensure the hashes match.

@jcfr
Copy link
Contributor

jcfr commented Nov 16, 2020

It looks like the .dylibs directory containing libomp.dylib is properly packaged in the .tar.gz file but there is a problem extracting the content of the archive into its final destination.

See https://github.com/Slicer/Slicer/blob/893da2c678b5138f3eece20d3b41b9cdaa04afa5/Base/QTCore/qSlicerExtensionsManagerModel.cxx#L2459-L2543

@jcfr
Copy link
Contributor

jcfr commented Nov 19, 2020

This has been fixed in Slicer/Slicer#5307

@luciacev luciacev reopened this Mar 18, 2021
@luciacev
Copy link
Author

@bpaniagua @allemangD @jcfr
ShapeVariationAnalyzer does not show and instead in the SlicerCMF index when we click on ShapeVariationAnalyzer a module Population Analysis starts that does not seem to allow computing group averages or group differences , and is quite different from SVA.
Not sure how to report this issue and will further clarify with Bea in June.

@allemangD
Copy link

allemangD commented May 20, 2021

@luciacev The fix for this bug required a change to Slicer, so the stable version from Sep. 2020 that we had told you to use (4.11.20200930) would not contain that fix.

I've confirmed that SVA loads correctly on Mac in the latest stable version from Feb. 2021 (4.11.20210226). As best I can tell, all the other modules work correctly there, too. I would recommend we try to use the latest stable version moving forward.

Regarding DCBIA-OrthoLab/SlicerCMF#13, SPHARM-PDM is available on Mac in that version, but not RigidAlignment. I'm working on fixing that next.

I've made notes about these in the weekly updates document, and will send that out to the team this Friday.

Downloads for the Feb. 2021 stable version here.

@allemangD
Copy link

Closing as the issue is fixed in the current stable release 4.11.20210226.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants