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

Fix examples/Sphere/generate_initial_conditions.py #274

Merged

Conversation

CFD-Xing
Copy link
Contributor

@CFD-Xing CFD-Xing commented Jun 24, 2024

The python script in examples/Sphere/generate_initial_conditions.py is broken.

First the from_stl function should only accept keyword argument. Providing the filename as a positional argument cause the following error:

epsi
Traceback (most recent call last):
  File "generate_initial_conditions.py", line 17, in <module>
    epsi[key] = epsi[key].geo.from_stl("sphere.stl",
TypeError: from_stl() takes 1 positional argument but 2 positional arguments (and 3 keyword-only arguments) were given

A lower case d should be use in gene_epsi_3D. The current script produce the following error:

Traceback (most recent call last):
  File "generate_initial_conditions.py", line 22, in <module>
    dataset = x3d.gene_epsi_3D(epsi, prm)
AttributeError: module 'xcompact3d_toolbox' has no attribute 'gene_epsi_3D'

This PR fix this issue.

@slaizet slaizet merged commit 2c7be99 into xcompact3d:master Jun 26, 2024
1 check passed
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.

None yet

2 participants