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

ENH: Add ARM builds and notebook test #70

Merged
merged 3 commits into from
Jan 19, 2023

Conversation

tbirdso
Copy link
Contributor

@tbirdso tbirdso commented Jan 6, 2023

Applies recent changes in ITKRemoteModuleBuildTestPackageAction to add Jupyter Notebook tests to CI.

Includes fix for itk.SplitComponentsImageFilter wrapping where the number of components to split for RGB/RGBA images was tied to the image dimension rather than the implied pixel dimension.

Updates to latest reusable workflow commit to include ARM builds and
improved Linux job scheduling. Also enables notebook tests.
@tbirdso
Copy link
Contributor Author

tbirdso commented Jan 6, 2023

@thewtex Glancing back through ITKSplitComponents.ipynb notebook errors in my local Linux installation with itkwidgets==1.0a21, the example made use of ipywidgets components such as HBox, VBox, and interactive. Are these supported in itkwidgets>=1.0a21? Is there a better way to visualize scrolling through distinct image channels?

EDIT: Initial test run here uses itkwidgets==0.32.5 and seems to fail at first view: https://github.com/tbirdso/ITKSplitComponents/actions/runs/3850782393

@thewtex
Copy link
Member

thewtex commented Jan 6, 2023

ipywidget support in 1.0 is in progress (tracked in InsightSoftwareConsortium/itkwidgets#556).

FAILED examples/ITKSplitComponents.ipynb:: - TraitError: label_image_weights shape expected to have 1 components, but got () components

This should have been addressed with 0.32.5 re: InsightSoftwareConsortium/itkwidgets#588

Care may need to be taken in how jupyter / itkwidgets is installed to ensure traitlets is < 5.7?

@tbirdso
Copy link
Contributor Author

tbirdso commented Jan 6, 2023

It does look like traitlets 5.8 is installed, will update requirements.txt. From the log:

Downloading traitlets-5.8.0-py3-none-any.whl

Resolves issues identified in automated Python notebook testing:
- The number of components to split with `SplitComponentsImageFilter`
  is now fixed at 3 for RGB and 4 for RGBA images rather than being
  defined by the image dimension. Under previous behavior only the
   first two RG components could be extracted for a 2D image.
- Updated to use pythonic `itk.image_duplicator`
- Downgrades `traitlets` for compatibility with `itkwidgets==0.32.5`

Also updates `.gitignore` to ignore example artifacts.
@tbirdso
Copy link
Contributor Author

tbirdso commented Jan 6, 2023

Downgrading to traitlets<5.7.0 in requirements.txt resolved the issue 👍

https://github.com/InsightSoftwareConsortium/ITKSplitComponents/actions/runs/3858346527/jobs/6576762362

Rebased and ready for review.

@tbirdso tbirdso marked this pull request as ready for review January 6, 2023 21:40
@tbirdso tbirdso changed the title WIP: Add Notebook Test ENH: Add ARM builds and notebook test Jan 6, 2023
@tbirdso tbirdso requested a review from dzenanz January 13, 2023 20:24
Copy link
Member

@dzenanz dzenanz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good on a glance.

@tbirdso tbirdso merged commit 03e0a80 into InsightSoftwareConsortium:master Jan 19, 2023
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 this pull request may close these issues.

3 participants