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

Compat with ultraliser 0.4.0 #16

Closed
arnaudon opened this issue Jan 29, 2024 · 5 comments
Closed

Compat with ultraliser 0.4.0 #16

arnaudon opened this issue Jan 29, 2024 · 5 comments

Comments

@arnaudon
Copy link
Contributor

The command here does not work at all with latest module of ultraliser:

https://github.com/BlueBrain/atlas-placement-hints/blob/main/atlas_placement_hints/distances/create_watertight_mesh.py#L113

@marwan-abdellah , I'm not even sure ( I couldn't find changelog) on how to map the old/new options, could you give me a mapping? thanks!

@arnaudon
Copy link
Contributor Author

With 0.3.0 it works, but I get a

	Computing Edges 
	* Progress │▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒│ (100.00 %) 
	* Time     | 0.0307088 Seconds 

	Removing Vertices 
	* Progress │▒▒                                                │ (4.62 %)Some polygons are NOT closed: @[9672] 

@arnaudon arnaudon changed the title Comapt with ultraliser 0.4.0 Compat with ultraliser 0.4.0 Jan 29, 2024
@arnaudon
Copy link
Contributor Author

With 0.4.0 and playing with parameters, I get a seg fault straight away

@arnaudon
Copy link
Contributor Author

arnaudon commented Jan 29, 2024

Ah this was already noticed here: #9

@marwan-abdellah
Copy link
Member

Just replace tyour code with this please:

if Path(volume_path).suffix:
        raise ValueError(
            "[ultra_volume_2_mesh] "
            f"The provided option 'volume_path' {volume_path} has a non-empty file extension. "
            f"The program ultraVolume2mesh expects a filepath without extension."
        )
    subprocess.check_output(
        [
            ultra_volume_2_mesh_path,
            "--volume-path",
            volume_path,
            "--iso-value",
            str(iso_value),
            "--export-obj-mesh",
            "--optimize-mesh",
            "--smooth-iterations",
            str(smooth_iterations),
            "--output-directory",
            output_directory,
        ]
    )

@asoplata
Copy link
Contributor

@arnaudon If you're trying to update atlas-placement-hints to use ultraliser v0.4.0, the main difficulty might be updating the tests so that they pass. The current tests are hardcoded to use a very old version of ultraliser here: https://github.com/BlueBrain/atlas-placement-hints/blob/main/tests/distances/test_create_watertight_mesh.py#L20-L22

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

No branches or pull requests

3 participants