ansys / pyacp

Python Client for Ansys Composite PrepPost
https://acp.docs.pyansys.com
MIT License
4 stars 1 forks source link

visualization issue, no arrows in plots #494

Closed mcMunich closed 7 months ago

mcMunich commented 8 months ago

🔍 Before submitting the issue

🐞 Description of the bug

Running the first example and trying to get the visualizations of the arrows to work (example: orientation). image The examples have the arrows/vectors which allows users to visualize the requested quantities/directions.

📝 Steps to reproduce

run 001_basic_falt_plate.py

my launch (modules)_

if not exist "C:\%myvenv%" (
python -m venv "C:\%myvenv%"
call "C:\%myvenv%\Scripts\activate"
"C:\%myvenv%\Scripts\python" -m pip install --upgrade pip
"C:\%myvenv%\Scripts\pip" install spyder-kernels==2.5
"C:\%myvenv%\Scripts\pip" install spyder
"C:\%myvenv%\Scripts\pip" install jupyterlab
"C:\%myvenv%\Scripts\pip" install ansys-mapdl-core
"C:\%myvenv%\Scripts\pip" install ansys-dpf-core
"C:\%myvenv%\Scripts\pip" install ansys-dpf-composites
"C:\%myvenv%\Scripts\pip" install trame
"C:\%myvenv%\Scripts\pip" install pyvista 
"C:\%myvenv%\Scripts\pip" install pyvista[jupyter,trame]
"C:\%myvenv%\Scripts\pip" install --upgrade pyiges[full]
pip install git+https://<TOKEN>@github.com/ansys/pyacp.git
"C:\%myvenv%\Scripts\spyder.exe"

)

💻 Which operating system are you using?

Windows

📀 Which ANSYS version are you using?

guessing it requires 24r2

🐍 Which Python version are you using?

3.12

📦 Installed packages

!pip freeze
aiohttp==3.9.3
aiosignal==1.3.1
alabaster==0.7.16
ansys-acp-core @ git+https://github.com/ansys/pyacp.git@1e790bb17376d580cb8e968f9da078eaed9c55eb
ansys-api-acp==0.1.0.dev8
ansys-api-mapdl==0.5.1
ansys-api-platform-instancemanagement==1.0.0
ansys-api-tools-filetransfer==0.1.0
ansys-dpf-composites==0.4.0
ansys-dpf-core==0.11.0
ansys-mapdl-core==0.68.0
ansys-mapdl-reader==0.53.0
ansys-math-core==0.1.3
ansys-platform-instancemanagement==1.1.2
ansys-tools-filetransfer==0.1.0
ansys-tools-local-product-launcher==0.1.0
ansys-tools-path==0.4.1
anyio==4.3.0
appdirs==1.4.4
argon2-cffi==23.1.0
argon2-cffi-bindings==21.2.0
arrow==1.3.0
astroid==3.0.3
asttokens==2.4.1
async-lru==2.0.4
atomicwrites==1.4.1
attrs==23.2.0
autopep8==2.0.4
Babel==2.14.0
backports.entry-points-selectable==1.3.0
bcrypt==4.1.2
beautifulsoup4==4.12.3
binaryornot==0.4.4
black==24.2.0
bleach==6.1.0
cachetools==5.3.3
certifi==2024.2.2
cffi==1.16.0
chardet==5.2.0
charset-normalizer==3.3.2
click==8.1.7
cloudpickle==3.0.0
colorama==0.4.6
comm==0.2.1
contourpy==1.2.0
cookiecutter==2.6.0
cryptography==42.0.5
cycler==0.12.1
debugpy==1.8.1
decorator==5.1.1
defusedxml==0.7.1
diff-match-patch==20230430
dill==0.3.8
docstring-to-markdown==0.15
docutils==0.20.1
executing==2.0.1
fastjsonschema==2.19.1
flake8==7.0.0
fonttools==4.49.0
fqdn==1.5.1
frozenlist==1.4.1
geomdl==5.3.1
google-api-core==2.17.1
google-api-python-client==2.121.0
google-auth==2.28.2
google-auth-httplib2==0.2.0
googleapis-common-protos==1.63.0
grpcio==1.62.1
grpcio-health-checking==1.62.1
h11==0.14.0
httpcore==1.0.4
httplib2==0.22.0
httpx==0.27.0
idna==3.6
imagesize==1.4.1
importlib_metadata==7.0.2
inflection==0.5.1
intervaltree==3.1.0
ipykernel==6.29.3
ipython==8.22.2
ipywidgets==8.1.2
isoduration==20.11.0
isort==5.13.2
jaraco.classes==3.3.1
jedi==0.19.1
jellyfish==1.0.3
Jinja2==3.1.3
json5==0.9.22
jsonpointer==2.4
jsonschema==4.21.1
jsonschema-specifications==2023.12.1
jupyter-events==0.9.0
jupyter-lsp==2.2.4
jupyter_client==8.6.0
jupyter_core==5.7.1
jupyter_server==2.13.0
jupyter_server_proxy==4.1.0
jupyter_server_terminals==0.5.2
jupyterlab==4.1.4
jupyterlab_pygments==0.3.0
jupyterlab_server==2.25.3
jupyterlab_widgets==3.0.10
keyring==24.3.1
kiwisolver==1.4.5
markdown-it-py==3.0.0
MarkupSafe==2.1.5
matplotlib==3.8.3
matplotlib-inline==0.1.6
mccabe==0.7.0
mdurl==0.1.2
mistune==3.0.2
more-itertools==10.2.0
multidict==6.0.5
mypy-extensions==1.0.0
nbclient==0.9.0
nbconvert==7.16.2
nbformat==5.9.2
nest-asyncio==1.6.0
notebook_shim==0.2.4
numpy==1.26.4
numpydoc==1.6.0
overrides==7.7.0
packaging==24.0
pandocfilters==1.5.1
paramiko==3.4.0
parso==0.8.3
pathspec==0.12.1
pexpect==4.9.0
pickleshare==0.7.5
pillow==10.2.0
platformdirs==4.2.0
pluggy==1.4.0
pooch==1.8.1
prometheus_client==0.20.0
prompt-toolkit==3.0.43
protobuf==4.25.3
psutil==5.9.8
ptyprocess==0.7.0
pure-eval==0.2.2
pyansys-tools-versioning==0.5.0
pyasn1==0.5.1
pyasn1-modules==0.3.0
pycodestyle==2.11.1
pycparser==2.21
pydocstyle==6.3.0
pyflakes==3.2.0
Pygments==2.17.2
pyiges==0.3.1
pylint==3.0.4
pylint-venv==3.0.3
pyls-spyder==0.4.0
PyNaCl==1.5.0
pyparsing==3.1.2
PyQt5==5.15.10
PyQt5-Qt5==5.15.2
PyQt5-sip==12.13.0
PyQtWebEngine==5.15.6
PyQtWebEngine-Qt5==5.15.2
python-dateutil==2.9.0.post0
python-json-logger==2.0.7
python-lsp-black==2.0.0
python-lsp-jsonrpc==1.1.2
python-lsp-server==1.10.0
python-slugify==8.0.4
pytoolconfig==1.3.1
pyvista==0.43.3
pywin32==306
pywin32-ctypes==0.2.2
pywinpty==2.0.13
PyYAML==6.0.1
pyzmq==25.1.2
QDarkStyle==3.2.3
qstylizer==0.2.2
QtAwesome==1.3.0
qtconsole==5.5.1
QtPy==2.4.1
referencing==0.33.0
requests==2.31.0
rfc3339-validator==0.1.4
rfc3986-validator==0.1.1
rich==13.7.1
rope==1.12.0
rpds-py==0.18.0
rsa==4.9
Rtree==1.2.0
scipy==1.12.0
scooby==0.9.2
Send2Trash==1.8.2
setuptools==69.1.1
simpervisor==1.0.0
six==1.16.0
sniffio==1.3.1
snowballstemmer==2.2.0
sortedcontainers==2.4.0
soupsieve==2.5
Sphinx==7.2.6
sphinxcontrib-applehelp==1.0.8
sphinxcontrib-devhelp==1.0.6
sphinxcontrib-htmlhelp==2.0.5
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.7
sphinxcontrib-serializinghtml==1.1.10
spyder==5.5.1
spyder-kernels==2.5.0
stack-data==0.6.3
tabulate==0.9.0
terminado==0.18.0
text-unidecode==1.3
textdistance==4.6.1
three-merge==0.1.1
tinycss2==1.2.1
tomli==2.0.1
tomlkit==0.12.4
tornado==6.4
tqdm==4.66.2
traitlets==5.14.1
trame==3.5.2
trame-client==2.16.2
trame-server==2.17.2
trame-vtk==2.8.5
trame-vuetify==2.4.2
types-python-dateutil==2.8.19.20240311
typing_extensions==4.10.0
ujson==5.9.0
uri-template==1.3.0
uritemplate==4.1.1
urllib3==2.2.1
vtk==9.3.0
watchdog==4.0.0
wcwidth==0.2.13
webcolors==1.13
webencodings==0.5.1
websocket-client==1.7.0
whatthepatch==1.0.5
widgetsnbextension==4.0.10
wslink==1.12.4
yapf==0.40.2
yarl==1.9.4
zipp==3.17.0
greschd commented 7 months ago

It appears the root cause here is average_element_size being 0.0 due to an install that is older than when this feature was added in the backend. @janvonrickenbach do you think we should special-case average_element_size being zero in the front-end (maybe compute it from the mesh data), or can this anyway not occur with recent builds?

greschd commented 7 months ago

As discussed offline with @janvonrickenbach and @roosre: In current builds, the average_element_size should always be present and non-zero. As such, it doesn't make sense to reimplement its logic in the front-end.

I'll close this issue for now. @mcMunich feel free to reopen if updating the install doesn't resolve it.