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

add polyhedral example #2505

Merged
merged 3 commits into from
Apr 25, 2022
Merged

add polyhedral example #2505

merged 3 commits into from
Apr 25, 2022

Conversation

akaszynski
Copy link
Member

Polyhedral Example

In response to #2503, this PR adds a basic polyhedral example to our docs:

points = np.array(
    [[0.0480, 0.0349, 0.9982],
     [0.0305, 0.0411, 0.9987],
     [0.0207, 0.0329, 0.9992],
     [0.0218, 0.0158, 0.9996],
     [0.0377, 0.0095, 0.9992],
     [0.0485, 0.0163, 0.9987],
     [0.0572, 0.0603, 0.9965],
     [0.0390, 0.0666, 0.9970],
     [0.0289, 0.0576, 0.9979],
     [0.0582, 0.0423, 0.9974],
     [0.0661, 0.0859, 0.9941],
     [0.0476, 0.0922, 0.9946],
     [0.0372, 0.0827, 0.9959],
     [0.0674, 0.0683, 0.9954]],
)


face_a = [6, 0, 1, 2, 3, 4, 5]
face_b = [6, 6, 7, 8, 1, 0, 9]
face_c = [6, 10, 11, 12, 7, 6, 13]
faces = np.hstack((face_a, face_b, face_c))

mesh = pv.PolyData(points, faces)
mesh.plot(show_edges=True, line_width=5)

image

@github-actions github-actions bot added the documentation Anything related to the documentation/website label Apr 24, 2022
@codecov
Copy link

codecov bot commented Apr 24, 2022

Codecov Report

Merging #2505 (5e77cc6) into main (6bb517c) will increase coverage by 0.04%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main    #2505      +/-   ##
==========================================
+ Coverage   93.70%   93.75%   +0.04%     
==========================================
  Files          75       75              
  Lines       16072    16072              
==========================================
+ Hits        15061    15069       +8     
+ Misses       1011     1003       -8     

Co-authored-by: Andras Deak <adeak@users.noreply.github.com>
Copy link
Member

@adeak adeak left a comment

Choose a reason for hiding this comment

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

Haven't built the docs yet but LGTM, thanks. One very weak suggestion that you can also just ignore.

examples/00-load/create-poly.py Outdated Show resolved Hide resolved
Co-authored-by: Andras Deak <adeak@users.noreply.github.com>
@akaszynski akaszynski enabled auto-merge (squash) April 24, 2022 23:39
@akaszynski akaszynski merged commit 7710b6c into main Apr 25, 2022
@akaszynski akaszynski deleted the docs/polyhedra-example branch April 25, 2022 00:07
adeak added a commit to adeak/pyvista that referenced this pull request Apr 28, 2022
* upstream/main:
  Make VTK version error clear when PointSet is still abstract (pyvista#2483)
  Use imageio intersphinx links (pyvista#2489)
  Fix glyphs when orienting with cell data (pyvista#2500)
  Bump mypy from 0.942 to 0.950 (pyvista#2522)
  Update hypothesis requirement from <6.45.1 to <6.45.2 (pyvista#2523)
  Add many Readers (pyvista#2496)
  Bump trimesh from 3.10.8 to 3.11.2 (pyvista#2519)
  Return actor from add_mesh_threshold (pyvista#2516)
  fix uniformgrid.x docstring (pyvista#2511)
  Update imageio requirement from <2.18.0 to <2.19.0 (pyvista#2506)
  Update hypothesis requirement from <6.44.1 to <6.45.1 (pyvista#2507)
  add polyhedral example (pyvista#2505)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Anything related to the documentation/website
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants