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: Read Windows pointers #1513

Merged
merged 1 commit into from
Mar 17, 2023
Merged

ENH: Read Windows pointers #1513

merged 1 commit into from
Mar 17, 2023

Conversation

cookpa
Copy link
Member

@cookpa cookpa commented Mar 17, 2023

Inspired by ANTsX/ANTsPy#437

Notice from the exception thrown there:

file 0000018600E3C1C0 does not exist . 
Exception Object caught: 

itk::ExceptionObject (0000000A275EBBC0)
Location: "unknown" 
File: D:\a\ANTsPy\ANTsPy\itksource\Modules\Registration\Common\include\itkCenteredTransformInitializer.hxx
Line: 31
Description: ITK ERROR: CenteredTransformInitializer(000001867F47D310): Fixed Image has not been set

On Windows the address is "0000018600E3C1C0" not "0x000018600E3C1C0", so it won't match the "0x" pattern, and ANTs attempts to read as a file from disk.

I've tried to modify the logic so that a hex string of the appropriate length (17 chars here) gets treated as a pointer also. My hope is that this will allow ANTsPy to work on Windows, but I can't test that directly.

The modified code does pass ANTs tests.

@cookpa cookpa merged commit 12cfa66 into master Mar 17, 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.

1 participant