diff --git a/doc/source/_static/css/landing_page.css b/doc/source/_static/css/projects_sidebar.css similarity index 94% rename from doc/source/_static/css/landing_page.css rename to doc/source/_static/css/projects_sidebar.css index 4ec146c5..a0076f88 100644 --- a/doc/source/_static/css/landing_page.css +++ b/doc/source/_static/css/projects_sidebar.css @@ -2,13 +2,13 @@ html { overflow-y: scroll !important; } -.landing-page-sidebar { +.projects-page-sidebar { margin-top: 2rem; display: flex; flex-direction: column; padding: 0rem 2rem; } -.landing-page-sidebar-section { +.projects-page-sidebar-section { margin-bottom: 2rem; font-weight: 700; display: flex; @@ -20,7 +20,7 @@ html { margin-top: 1rem; } -.landing-page-sidebar-section span { +.projects-page-sidebar-section span { font-size: 0.85rem; } @@ -112,7 +112,7 @@ html { grid-template-columns: 1fr; } - .landing-page-sidebar { + .projects-page-sidebar { padding: 1rem; } diff --git a/doc/source/_static/css/style.css b/doc/source/_static/css/style.css new file mode 100644 index 00000000..142832bf --- /dev/null +++ b/doc/source/_static/css/style.css @@ -0,0 +1,58 @@ +/* Remove breadcrumbs */ +.bd-header-article { + display: none !important; +} + +/* Maximize the width of the content area */ +.bd-main .bd-content { + display: flex !important; + height: 100% !important; + justify-content: center !important; +} + +.bd-main .bd-content .bd-article-container { + width: 100% !important; +} + +.center { + margin: 0 auto !important; +} + +#hero-image { + transition: opacity 0.5s ease-in-out; + opacity: 1; +} + +.fade-out { + opacity: 0; +} + +.fade-in { + opacity: 1; +} + +.section-divider { + display: flex; + align-items: center; + text-align: center; + margin: 40px 0; +} + +.section-divider::before, +.section-divider::after { + content: ""; + flex: 1; + height: 1px; + background: linear-gradient(to right, transparent, #000); +} + +.section-divider::after { + background: linear-gradient(to left, transparent, #000); +} + +.section-title { + padding: 0 20px; + font-size: 2.5rem; + font-weight: bold; + white-space: nowrap; +} diff --git a/doc/source/_static/js/blogs_sidebar.js b/doc/source/_static/js/blogs_sidebar.js new file mode 100644 index 00000000..3a2a8912 --- /dev/null +++ b/doc/source/_static/js/blogs_sidebar.js @@ -0,0 +1,253 @@ +document.addEventListener("DOMContentLoaded", () => { + const state = { + products: new Set(), + industries: new Set(), + tags: new Set(), + }; + const blogContainer = document.getElementById("blog-container"); + let allPosts = {}; + + function createCheckbox(name, containerId, type) { + const id = `${type}-${name}`; + + const wrapper = document.createElement("div"); + wrapper.className = "checkbox-wrapper"; + + const input = document.createElement("input"); + input.type = "checkbox"; + input.id = id; + input.value = name; + input.style.marginRight = "5px"; + + const label = document.createElement("label"); + label.setAttribute("for", id); + label.textContent = name; + label.style.cursor = "pointer"; + + input.addEventListener("change", () => { + if (input.checked) { + state[type].add(name); + } else { + state[type].delete(name); + } + updateVisiblePosts(); + updateTagFilter(); + // updateProductFilter(); + updateIndustryFilter(); + }); + + wrapper.appendChild(input); + wrapper.appendChild(label); + + const container = document.querySelector( + `#${containerId} .collapsible-content`, + ); + if (container) container.appendChild(wrapper); + } + + function generateFilters(data) { + const products = new Set(); + const industries = new Set(); + const tags = new Set(); + + for (const key in data) { + const post = data[key]; + + (post.products || "") + .split(",") + .map((p) => p.trim()) + .filter(Boolean) + .forEach((p) => products.add(p)); + (post.industries || "") + .split(",") + .map((c) => c.trim()) + .filter(Boolean) + .forEach((c) => industries.add(c)); + (post.tags || "") + .split(",") + .map((t) => t.trim()) + .filter(Boolean) + .forEach((t) => tags.add(t)); + } + + [...products] + .sort() + .forEach((p) => createCheckbox(p, "product-filters", "products")); + [...industries] + .sort() + .forEach((i) => createCheckbox(i, "industry-filters", "industries")); + [...tags].sort().forEach((t) => createCheckbox(t, "tag-filters", "tags")); + } + + function updateTagFilter() { + const selectedProducts = [...state.products]; + const selectedIndustries = [...state.industries]; + + for (const label of document.querySelectorAll("#tag-filters label")) { + const checkbox = label.querySelector("input[type=checkbox]"); + const value = checkbox.value; + + let isVisible = false; + + for (const key in allPosts) { + const post = allPosts[key]; + const postTags = (post.tags || "").split(",").map((t) => t.trim()); + const postProducts = (post.products || "") + .split(",") + .map((p) => p.trim()); + const postIndustries = (post.industries || "") + .split(",") + .map((c) => c.trim()); + + const matchProduct = + selectedProducts.length === 0 || + postProducts.some((p) => selectedProducts.includes(p)); + const matchIndustry = + selectedIndustries.length === 0 || + postIndustries.some((c) => selectedIndustries.includes(c)); + const matchTag = postTags.includes(value); + + if (matchProduct && matchIndustry && matchTag) { + isVisible = true; + break; + } + } + + label.style.display = isVisible ? "block" : "none"; + } + } + + // function updateProductFilter() { + // const selectedTags = [...state.tags]; + // const selectedIndustries = [...state.industries]; + // const productSet = new Set(); + + // for (const key in allPosts) { + // const post = allPosts[key]; + // const postProducts = (post.products || "").split(",").map(p => p.trim()); + // const postIndustries = (post.industries || "").split(",").map(c => c.trim()); + // const matchTag = selectedTags.length === 0 || (post.tags || "").split(",").map(t => t.trim()).some(t => selectedTags.includes(t)); + // const matchIndustry = selectedIndustries.length === 0 || postIndustries.some(c => selectedIndustries.includes(c)); + + // if (matchTag && matchIndustry) { + // postProducts.filter(Boolean).forEach(p => productSet.add(p)); + // } + // } + + // const container = document.querySelector("#product-filters .collapsible-content"); + // if (!container) return; + + // container.innerHTML = ""; + // [...productSet].sort().forEach(p => createCheckbox(p, "product-filters", "products")); + // } + + function updateIndustryFilter() { + const selectedTags = [...state.tags]; + const selectedProducts = [...state.products]; + const industrySet = new Set(); + + for (const key in allPosts) { + const post = allPosts[key]; + const postIndustries = (post.industries || "") + .split(",") + .map((c) => c.trim()); + const postProducts = (post.products || "") + .split(",") + .map((p) => p.trim()); + const matchTag = + selectedTags.length === 0 || + (post.tags || "") + .split(",") + .map((t) => t.trim()) + .some((t) => selectedTags.includes(t)); + const matchProduct = + selectedProducts.length === 0 || + postProducts.some((p) => selectedProducts.includes(p)); + + if (matchTag && matchProduct) { + postIndustries.filter(Boolean).forEach((c) => industrySet.add(c)); + } + } + + const container = document.querySelector( + "#industry-filters .collapsible-content", + ); + if (!container) return; + + container.innerHTML = ""; + [...industrySet] + .sort() + .forEach((c) => createCheckbox(c, "industry-filters", "industries")); + } + + function updateVisiblePosts() { + if (!blogContainer) return; + blogContainer.innerHTML = ""; + + for (const key in allPosts) { + const post = allPosts[key]; + const postProducts = (post.products || "") + .split(",") + .map((p) => p.trim()); + const postIndustries = (post.industries || "") + .split(",") + .map((c) => c.trim()); + const postTags = (post.tags || "").split(",").map((t) => t.trim()); + + const matchProduct = + state.products.size === 0 || + postProducts.some((p) => state.products.has(p)); + const matchIndustry = + state.industries.size === 0 || + postIndustries.some((c) => state.industries.has(c)); + const matchTag = + state.tags.size === 0 || postTags.some((t) => state.tags.has(t)); + + if (matchProduct && matchIndustry && matchTag) { + const postCard = document.createElement("div"); + postCard.className = "project-card sd-card sd-shadow-sm sd-card-hover"; + postCard.onclick = () => (window.location.href = `${key}.html`); + + const description = post.description || ""; + const shortDescription = + description.length > 100 + ? description.slice(0, 100) + "..." + : description; + + postCard.innerHTML = ` + ${post.image ? `${post.title || key}` : ""} +
+

${post.title || key}

+

${shortDescription}

+

+ ${post.author || "PyAnsys Team"}
+ ${post.date || "Unknown Date"} +

+ Read More +
+ `; + blogContainer.appendChild(postCard); + } + } + } + + function setupCollapsibles() { + document.querySelectorAll(".collapsible").forEach((button) => { + button.addEventListener("click", function () { + this.classList.toggle("active"); + const content = this.nextElementSibling; + content.style.display = + content.style.display === "block" ? "none" : "block"; + }); + }); + } + + fetch("/_static/blog_metadata.json") + .then((res) => res.json()) + .then((data) => { + allPosts = data; + setupCollapsibles(); + generateFilters(data); + updateVisiblePosts(); + }); +}); diff --git a/doc/source/_static/js/landing_page.js b/doc/source/_static/js/projects_sidebar.js similarity index 100% rename from doc/source/_static/js/landing_page.js rename to doc/source/_static/js/projects_sidebar.js diff --git a/doc/source/_static/landing-page/css/carousel.css b/doc/source/_static/landing-page/css/carousel.css new file mode 100644 index 00000000..d4deef94 --- /dev/null +++ b/doc/source/_static/landing-page/css/carousel.css @@ -0,0 +1,90 @@ +.carousel-item { + height: 30rem; + color: white; + border: thin solid black; +} + +.carousel-item::before { + z-index: 1; + position: absolute; + content: ""; + top: 0; + right: 0; + bottom: 0; + left: 0; + background: linear-gradient(to right, rgba(0, 0, 0, 1), rgba(0, 0, 0, 0.1)); +} + +.carousel-content { + z-index: 2; + position: absolute; + top: 10%; + left: 5%; + max-width: 40%; +} + +.carousel-content h2 { + font-size: 3rem; + color: white; +} + +.carousel-content p { + margin: 2rem 0; + font-size: 1.25rem; + color: white; +} + +.carousel-content .btn-custom { + background-color: #ffb71b; + color: black; + border: none; + border-radius: 0.25rem; + font-size: 0.75rem; + font-weight: bold; + padding: 0.75rem 1.25rem; + text-transform: uppercase; +} + +.carousel-indicators { + width: 100%; + height: 4rem; + margin: 0 auto; + padding: 0; + + background-color: rgba(0, 0, 0, 1); + + position: absolute; + bottom: -4rem; + + display: flex; + flex-direction: row; + justify-content: space-evenly; + align-items: center; + color: white; +} + +.carousel-indicators .active { + border-style: none none none solid; + border-left: 0.2rem solid #ffb71b !important; + border-radius: 0; +} + +.carousel-indicators [data-bs-target] { + color: white; + background: transparent; + + text-indent: 0rem; + font-weight: bold; + padding: 0.5rem 1.5rem; + height: 50%; + width: 75%; + text-align: left; + + border-style: none none none solid; + border-left: 0.2rem solid gray; + border-radius: 0; +} + +.carousel-indicators [data-bs-target]:first-child { + margin-left: 2rem; +} diff --git a/doc/source/_static/landing-page/css/style.css b/doc/source/_static/landing-page/css/style.css new file mode 100644 index 00000000..b2473afa --- /dev/null +++ b/doc/source/_static/landing-page/css/style.css @@ -0,0 +1,16 @@ +.testimonial-card { + background: #fff; + box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05); + border-radius: 0.5rem; + height: 100%; +} + +.carousel-control-prev-icon, +.carousel-control-next-icon { + background-color: black; +} + +.carousel-control-prev, +.carousel-control-next { + filter: invert(1); +} diff --git a/doc/source/_static/landing-page/css/testimonials.css b/doc/source/_static/landing-page/css/testimonials.css new file mode 100644 index 00000000..833099a5 --- /dev/null +++ b/doc/source/_static/landing-page/css/testimonials.css @@ -0,0 +1,7 @@ +/* Custom Styles for Testimonials */ +.testimonial { + transition: transform 0.3s ease; +} +.testimonial:hover { + transform: translateY(-5px); +} diff --git a/doc/source/_static/landing-page/drawings.svg b/doc/source/_static/landing-page/drawings.svg new file mode 100644 index 00000000..5d47bec5 --- /dev/null +++ b/doc/source/_static/landing-page/drawings.svg @@ -0,0 +1,102 @@ + + + + diff --git a/doc/source/_static/landing-page/js/testimonials.js b/doc/source/_static/landing-page/js/testimonials.js new file mode 100644 index 00000000..87f6df9e --- /dev/null +++ b/doc/source/_static/landing-page/js/testimonials.js @@ -0,0 +1,50 @@ +fetch("_static/landing-page/js/testimonials.json") + .then((response) => { + if (!response.ok) { + throw new Error(`HTTP error! Status: ${response.status}`); + } + return response.json(); + }) + .then((data) => { + const container = document.getElementById("testimonials-container"); + if (!container) { + console.error("Container element not found."); + return; + } + + data.forEach((testimonial) => { + const col = document.createElement("div"); + col.className = "col-md-4 mb-4"; + + const author = document.createElement("h2"); + author.className = "text-left"; + author.textContent = testimonial.author; + + const content = document.createElement("p"); + content.className = "mb-0"; + content.textContent = testimonial.content; + + const logo = document.createElement("img"); + logo.src = testimonial.logo; + logo.className = "rounded-circle mt-auto align-self-end"; + logo.style.height = "80px"; + logo.style.width = "auto"; + logo.alt = testimonial.author || "Logo"; + + const topDiv = document.createElement("div"); + topDiv.appendChild(author); + topDiv.appendChild(content); + + const testimonialDiv = document.createElement("div"); + testimonialDiv.className = + "testimonial p-4 bg-white rounded shadow-sm h-100 d-flex flex-column"; + testimonialDiv.appendChild(topDiv); + testimonialDiv.appendChild(logo); + + col.appendChild(testimonialDiv); + container.appendChild(col); + }); + }) + .catch((error) => { + console.error("Error loading testimonials:", error); + }); diff --git a/doc/source/_static/landing-page/js/testimonials.json b/doc/source/_static/landing-page/js/testimonials.json new file mode 100644 index 00000000..e6eb7676 --- /dev/null +++ b/doc/source/_static/landing-page/js/testimonials.json @@ -0,0 +1,17 @@ +[ + { + "author": "Actemium", + "content": "PyAnsys played a pivotal role in the optimization of our industrial cooling applications, recognized with the Environmental Award for Technological Breakthrough 2024.", + "logo": "https://www.actemium.es/app/uploads/sites/203/2022/10/logo-actemium@3x.png" + }, + { + "author": "NVIDIA", + "content": "PyAnsys leverages NVIDIA Omniverse to seamlessly integrate with solvers, delivering the visualizations that customers need.", + "logo": "https://nvidianews.nvidia.com/_gallery/get_file/?file_id=544a6120f6091d588d000048" + }, + { + "author": "STMicroelectronics", + "content": "PyAnsys is a game-changing tool for anyone in simulation and design. It offers significant reductions in design time, enhanced consistency, and streamlined operations. It reinforces STMicroelectronics' commitment to quality.", + "logo": "https://www.st.com/content/dam/st-crew/st-logo-blue.svg" + } +] diff --git a/doc/source/_static/landing-page/vtksz/geometry.vtksz b/doc/source/_static/landing-page/vtksz/geometry.vtksz new file mode 100644 index 00000000..1f1f46b2 Binary files /dev/null and b/doc/source/_static/landing-page/vtksz/geometry.vtksz differ diff --git a/doc/source/_static/landing-page/vtksz/mesh.vtksz b/doc/source/_static/landing-page/vtksz/mesh.vtksz new file mode 100644 index 00000000..0d7a7f5a Binary files /dev/null and b/doc/source/_static/landing-page/vtksz/mesh.vtksz differ diff --git a/doc/source/_static/landing-page/vtksz/results.vtksz b/doc/source/_static/landing-page/vtksz/results.vtksz new file mode 100644 index 00000000..7b6f163b Binary files /dev/null and b/doc/source/_static/landing-page/vtksz/results.vtksz differ diff --git a/doc/source/_static/static_viewer.html b/doc/source/_static/static_viewer.html new file mode 100644 index 00000000..9ed703d3 --- /dev/null +++ b/doc/source/_static/static_viewer.html @@ -0,0 +1,13 @@ + + + + + + + +
+ + + diff --git a/doc/source/_templates/blog.html b/doc/source/_templates/blog.html new file mode 100644 index 00000000..8df34213 --- /dev/null +++ b/doc/source/_templates/blog.html @@ -0,0 +1,24 @@ +{% extends "!layout.html" %} + +{% block docs_main %} +
+
+

Latest Posts

+
+ {% for post in blog_posts %} +
+ + {{ post.title or post.docname }} + +

+ {{ post.author or "Unknown" }} • {{ post.date or "No date" }} +

+

+ {{ post.summary or "No summary available." }} +

+
+ {% endfor %} +
+
+
+{% endblock %} diff --git a/doc/source/_templates/blogs_sidebar.html b/doc/source/_templates/blogs_sidebar.html new file mode 100644 index 00000000..6f571ac9 --- /dev/null +++ b/doc/source/_templates/blogs_sidebar.html @@ -0,0 +1,72 @@ +
+ +

Filters

+ +
+ + +
+ +
+ + +
+ +
+ + +
+ +
+ + + + + + + + + + + \ No newline at end of file diff --git a/doc/source/_templates/landing_page_sidebar.html b/doc/source/_templates/projects_sidebar.html similarity index 68% rename from doc/source/_templates/landing_page_sidebar.html rename to doc/source/_templates/projects_sidebar.html index 0db396f6..0d788e33 100644 --- a/doc/source/_templates/landing_page_sidebar.html +++ b/doc/source/_templates/projects_sidebar.html @@ -1,7 +1,7 @@ -
+
-
+
Product families
@@ -11,7 +11,7 @@
-
+
Tags
@@ -23,4 +23,4 @@ - + diff --git a/doc/source/api.rst b/doc/source/api.rst deleted file mode 100644 index a6159fd5..00000000 --- a/doc/source/api.rst +++ /dev/null @@ -1,34 +0,0 @@ -API reference -============= - -The ``pyansys`` metapackage on its own does not have a specific API. The only information specific-only -to this package that can be provided is its version. This can be looked up as follows: - -.. code-block:: pycon - - >>> from pyansys import __version__ - >>> __version__ - - '2023.1.0' - -However, each of the PyAnsys packages that shape the ``pyansys`` metapackage have their own specific API -reference section. In order to navigate through them, please refer to their documentation. - -****************************** -PyAnsys packages API reference -****************************** - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'Tools' not in metadata['family'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: {{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['api'] }} - :class-title: pyansys-card-title - - {% endif %} - {% endfor %} \ No newline at end of file diff --git a/doc/source/blog.rst b/doc/source/blog.rst new file mode 100644 index 00000000..726c3bc3 --- /dev/null +++ b/doc/source/blog.rst @@ -0,0 +1,91 @@ +Blog +#### + +The PyAnsys blog is a collection of articles and tutorials from the PyAnsys team and community. +It covers a wide range of topics related to the PyAnsys ecosystem, keeps you up to date with the latest developments, +and provides insights into how to use the various PyAnsys packages effectively. + +.. raw:: html + +
+ +
+ + + + +.. toctree:: + :maxdepth: 2 + :hidden: + + blog/blog1 + blog/blog2 + diff --git a/doc/source/blog/blog1.rst b/doc/source/blog/blog1.rst new file mode 100644 index 00000000..975f8d8e --- /dev/null +++ b/doc/source/blog/blog1.rst @@ -0,0 +1,20 @@ +.. meta:: + :author: Revathy + :date: 2025-05-14 + :categories: Development, CI/CD + :tags: mapdl, python + :industries: Aerospace, Automotive + :products: PyMAPDL + :image: thumbnails/5gwizard.png + :title: Blog Title One + :description: This is a sample blog post description. + +Blog Title One +============== + +.. image:: /_static/blog/image1.jpg + :alt: Blog image + :class: blog-banner + +Content goes here. + diff --git a/doc/source/blog/blog2.rst b/doc/source/blog/blog2.rst new file mode 100644 index 00000000..6b8d9fc7 --- /dev/null +++ b/doc/source/blog/blog2.rst @@ -0,0 +1,19 @@ +.. meta:: + :author: Revathy + :date: 2025-05-14 + :categories: product + :tags: speos, python + :industries: optical + :products: pyspeos + :image: thumbnails/5gwizard.png + :title: Blog Title two + :description: This is a sample blog post description. with a longer description to test the layout and ensure that it wraps correctly within the card. This is a sample blog post description with a longer description to test the layout and ensure that it wraps correctly within the card. This is a sample blog post description with a longer description to test the layout and ensure that it wraps correctly within the card. This is a sample blog post description with a longer description to test the layout and ensure that it wraps correctly within the card. + +Blog Title One +============== + +.. image:: /_static/blog/image1.jpg + :alt: Blog image + :class: blog-banner + +Content goes here. \ No newline at end of file diff --git a/doc/source/conf.py b/doc/source/conf.py index d8dc5a8e..c7af744d 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -71,7 +71,9 @@ html_favicon = ansys_favicon html_sidebars = { - "index": ["landing_page_sidebar.html"], + "index": [], + "projects": ["projects_sidebar.html"], + "blog": ["blogs_sidebar.html"], } extensions = [ @@ -84,7 +86,14 @@ # Static files templates_path = ["_templates"] html_static_path = ["_static"] -html_css_files = ["css/landing_page.css"] +html_css_files = [ + "css/style.css", + "css/projects_sidebar.css", + # Landing page specific CSS files + "landing-page/css/carousel.css", + "landing-page/css/style.css", + "landing-page/css/testimonials.css", +] metadata = Path(__file__).parent.parent.parent / "projects.yaml" @@ -159,6 +168,7 @@ def get_last_metapackage_release(): "needs_datatables": True, }, }, + "default_mode": "light", } html_theme_options = { @@ -168,17 +178,13 @@ def get_last_metapackage_release(): "show_breadcrumbs": True, "collapse_navigation": True, "use_edit_page_button": True, - "icon_links": [ - { - "name": "Support", - "url": "https://github.com/ansys/pyansys/discussions", - "icon": "fa fa-comment fa-fw", - }, - { - "name": "Contribute", - "url": "https://dev.docs.pyansys.com/how-to/contributing.html", - "icon": "fa fa-wrench", - }, + "secondary_sidebar_items": { + "**": ["page-toc", "sourcelink"], + "index": ["page-toc"], + }, + "navbar_end": [ + "navbar-icon-links", + "version-switcher", ], "switcher": { "json_url": f"https://{cname}/versions.json", @@ -534,3 +540,28 @@ def setup(app: sphinx.application.Sphinx): # Reverting the thumbnails - no local changes app.connect("build-finished", revert_thumbnails) + app.connect("doctree-resolved", collect_blog_metadata) + + +from docutils import nodes + + +def collect_blog_metadata(app, doctree, docname): + meta = {} + if docname.startswith("blog/"): # Check if it's a blog post + for node in doctree.traverse(nodes.meta): + meta[node["name"]] = node["content"] + if not hasattr(app.env, "blog_posts"): + app.env.blog_posts = {} + app.env.blog_posts[docname] = meta + + # Save metadata to a JSON file in the build directory + if hasattr(app.env, "blog_posts"): + blog_data = app.env.blog_posts + with open(app.builder.outdir + "/_static/blog_metadata.json", "w") as json_file: + json.dump(blog_data, json_file, indent=4) + + +# html_additional_pages = { +# 'blog': 'blog.html', +# } diff --git a/doc/source/examples.rst b/doc/source/examples.rst deleted file mode 100644 index 7aa3df21..00000000 --- a/doc/source/examples.rst +++ /dev/null @@ -1,29 +0,0 @@ -Examples -======== - -Examples for the different ``pyansys`` packages can be found in their specific documentation. - -************************* -PyAnsys packages examples -************************* - -.. note:: Combining PyAnsys libraries? - - If you are using multiple PyAnsys libraries, you can find examples on how to combine them - in the `PyAnsys Workflows `_ page. This page contains - practical examples on how to chain different PyAnsys libraries together. - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'Tools' not in metadata['family'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: {{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['examples'] }} - :class-title: pyansys-card-title - - {% endif %} - {% endfor %} \ No newline at end of file diff --git a/doc/source/getting-started/install.rst b/doc/source/getting-started/install.rst index 8ca6723f..0c58ae50 100644 --- a/doc/source/getting-started/install.rst +++ b/doc/source/getting-started/install.rst @@ -12,18 +12,21 @@ Download and install PyAnsys from `PyPI`_: .. tab-set:: .. tab-item:: :fab:`windows` **Windows** + :name: windows .. code-block:: bash python -m pip install pyansys .. tab-item:: :fab:`apple` **MacOS** + :name: macos .. code-block:: bash python -m pip install pyansys .. tab-item:: :fab:`linux` **Linux** + :name: linux .. code-block:: bash @@ -152,3 +155,30 @@ Finally, install the PyAnsys metapackage using previously downloaded wheelhouse: .. code-block:: bash python -m pip install pyansys -f wheelhouse --no-index --upgrade --ignore-installed + + +.. DO NOT MODIFY THE FOLLOWING SECTION + +.. raw:: html + + + \ No newline at end of file diff --git a/doc/source/index.rst b/doc/source/index.rst index 65057d80..de2a50b8 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -1,48 +1,131 @@ -======= -PyAnsys -======= +.. title:: PyAnsys -Welcome to the PyAnsys project. While this project originated as a single ``pyansys`` package, -it is now a collection of many Python packages for using Ansys products through Python: +.. raw:: html -.. toctree:: - :hidden: - :maxdepth: 3 - - getting-started - user_guide - api - examples - tools/index - -.. jinja:: project_context - - .. raw:: html - -
- {% for project, metadata in projects['projects'].items() %} - - {% set family = metadata.get('family', 'other') | lower | replace(' ', '-') %} - {% set tags = metadata.get('tags', 'other') | lower %} - -
- -
-

{{ metadata['name'] }}

-

{{ metadata['description'] }}

-

- {{ family.capitalize() }} - {% for tag in metadata['tags'] %} - {{ tag }} - {% endfor %} -

-
+ + + +
+ Explore PyAnsys possibilities +
+ + +
+
+ + +
+
+ +
+
Pre-process your simulation
+

Define your simulation setup by specifying the geometry in a flexible, parametric format. Clearly establish boundary and initial conditions to ensure accurate modeling of physical behaviors. This foundational step enables precise control over your simulation environment and sets the stage for meaningful analysis.

+
+
+
+ + +
+
+ +
+
Simulate and collect results
+

Run high-fidelity simulations and gather comprehensive results that reflect the dynamics of your system. Leverage powerful computational tools to model complex scenarios, validate designs, and explore different configurations. These insights help you make informed decisions based on real-time simulation outputs.

+
+
- {% endfor %} + +
+
+ +
+
Post-process your results
+

Extract, visualize, and interpret key data from your simulation to drive the next phase of your project. Post-processing tools help identify trends, highlight performance metrics, and transform raw output into actionable information. This step ensures your workflow remains efficient and results-oriented.

+
+
+ +
+
+ + +
+ Testimonials +
+ +
+
+
+
+
+ + + + + + + + +.. toctree:: + :hidden: + :maxdepth: 3 + + Home + getting-started + projects + blog diff --git a/doc/source/links.rst b/doc/source/links.rst index ca80fa85..5fefc01a 100644 --- a/doc/source/links.rst +++ b/doc/source/links.rst @@ -11,10 +11,12 @@ .. ANSYS and products .. _ANSYS, Inc.: https://www.ansys.com +.. _Ansys: https://www.ansys.com .. _Ansys products: https://www.ansys.com/products .. _Ansys Customer Portal: https://download.ansys.com .. Python libraries +.. _Python: https://www.python.org/ .. _PyPI: https://pypi.org/ .. _Numpy: https://numpy.org/ .. _SciPy: https://www.scipy.org/ diff --git a/doc/source/projects.rst b/doc/source/projects.rst new file mode 100644 index 00000000..16244823 --- /dev/null +++ b/doc/source/projects.rst @@ -0,0 +1,34 @@ +Projects +######## + +.. jinja:: project_context + + .. raw:: html + +
+ {% for project, metadata in projects['projects'].items() %} + + {% set family = metadata.get('family', 'other') | lower | replace(' ', '-') %} + {% set tags = metadata.get('tags', 'other') | lower %} + +
+ +
+

{{ metadata['name'] }}

+

{{ metadata['description'] }}

+

+ {{ family.capitalize() }} + {% for tag in metadata['tags'] %} + {{ tag }} + {% endfor %} +

+
+
+ + {% endfor %} +
diff --git a/doc/source/tools/index.rst b/doc/source/tools/index.rst deleted file mode 100644 index f3416e61..00000000 --- a/doc/source/tools/index.rst +++ /dev/null @@ -1,32 +0,0 @@ -Other tools -=========== - -Standalone projects, tooling libraries and toolkits related to the PyAnsys ecosystem. - -.. grid:: 1 - :gutter: 3 3 4 4 - - .. grid-item-card:: :octicon:`package` Standalone projects - :link: standalone/index - :link-type: doc - - Standalone projects to exploit the full potential of the PyAnsys ecosystem - - .. grid-item-card:: :octicon:`tools` Tooling libraries - :link: libraries/index - :link-type: doc - - Additional libraries delivered with the ``tools`` target of the PyAnsys metapackage - - .. grid-item-card:: :octicon:`gear` Toolkits - :link: toolkits/index - :link-type: doc - - Toolkits built on top of PyAnsys libraries for specific purposes. - -.. toctree:: - :hidden: - - standalone/index - libraries/index - toolkits/index \ No newline at end of file diff --git a/doc/source/tools/libraries/index.rst b/doc/source/tools/libraries/index.rst deleted file mode 100644 index c2bbc889..00000000 --- a/doc/source/tools/libraries/index.rst +++ /dev/null @@ -1,75 +0,0 @@ -Tooling libraries -================= - -.. grid:: 3 - :gutter: 3 3 4 4 - - .. grid-item-card:: Ansys FileTransfer Tool - :img-top: ../../_static/thumbnails/intro.png - :link: https://filetransfer.tools.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Simple gRPC API tool for moving files between a client and a remote server - - .. grid-item-card:: Ansys Local Product Launcher - :img-top: ../../_static/thumbnails/intro.png - :link: https://local-product-launcher.tools.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Python utility for launching Ansys products on a local machine and configuring their launch settings - - .. grid-item-card:: Ansys Tools Path - :img-top: ../../_static/thumbnails/intro.png - :link: https://path.tools.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Library to locate Ansys products in a local machine - - .. grid-item-card:: Ansys Tools Protobuf Compilation Helper - :img-top: ../../_static/thumbnails/intro.png - :link: https://ansys.github.io/ansys-tools-protoc-helper/ - :class-title: pyansys-card-title - - Utility library to compile ``.proto`` files to Python source when building the package wheel - - .. grid-item-card:: Ansys Tools Visualization interface - :img-top: ../../_static/thumbnails/intro.png - :link: https://visualization-interface.tools.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Python interface between PyAnsys libraries and plotting backends - - .. grid-item-card:: PyAnsys Tools Report - :img-top: ../../_static/thumbnails/intro.png - :link: https://report.tools.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Tool for reporting your Python environment's package versions and hardware resources in a standardized way - - .. grid-item-card:: PyAnsys Tools Variable Interop - :img-top: ../../_static/thumbnails/intro.png - :link: https://variableinterop.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Tool for defining basic variables, types, metadata, and values intended to provide interoperability between all products - - .. grid-item-card:: PyAnsys Tools Versioning - :img-top: ../../_static/thumbnails/intro.png - :link: https://versioning.tools.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Tool for backwards and forwards server support - - .. grid-item-card:: PyAnsys Units - :img-top: ../../_static/thumbnails/intro.png - :link: https://units.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Pythonic interface for units, unit systems, and unit conversions - - .. grid-item-card:: PyMaterials Manager - :img-top: ../../_static/thumbnails/intro.png - :link: https://manager.materials.docs.pyansys.com/version/stable - :class-title: pyansys-card-title - - Python package for unifying material management across the Ansys portfolio diff --git a/doc/source/tools/standalone/index.rst b/doc/source/tools/standalone/index.rst deleted file mode 100644 index 73f17457..00000000 --- a/doc/source/tools/standalone/index.rst +++ /dev/null @@ -1,99 +0,0 @@ -Standalone projects -=================== - -.. contents:: - -General purpose ---------------- - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'General purpose' in metadata['tags'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: ../../{{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['base'] }} - :class-title: pyansys-card-title - - {{ metadata['description'] }} - {% endif %} - {% endfor %} - -Demo purposes -------------- - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'Demo' in metadata['tags'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: ../../{{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['base'] }} - :class-title: pyansys-card-title - - {{ metadata['description'] }} - {% endif %} - {% endfor %} - -Repository management ---------------------- - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'Repository management' in metadata['tags'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: ../../{{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['base'] }} - :class-title: pyansys-card-title - - {{ metadata['description'] }} - {% endif %} - {% endfor %} - -Artificial intelligence ------------------------ - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'Artificial intelligence' in metadata['tags'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: ../../{{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['base'] }} - :class-title: pyansys-card-title - - {{ metadata['description'] }} - {% endif %} - {% endfor %} - -Documentation -------------- - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'Documentation' in metadata['tags'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: ../../{{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['base'] }} - :class-title: pyansys-card-title - - {{ metadata['description'] }} - {% endif %} - {% endfor %} diff --git a/doc/source/tools/toolkits/index.rst b/doc/source/tools/toolkits/index.rst deleted file mode 100644 index 16832855..00000000 --- a/doc/source/tools/toolkits/index.rst +++ /dev/null @@ -1,22 +0,0 @@ -PyAnsys toolkits -================ - -.. contents:: - -PyAEDT toolkits ---------------- -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'PyAEDT toolkits' in metadata['tags'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: ../../{{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['base'] }} - :class-title: pyansys-card-title - - {{ metadata['description'] }} - {% endif %} - {% endfor %} \ No newline at end of file diff --git a/doc/source/user_guide.rst b/doc/source/user_guide.rst deleted file mode 100644 index 721c9099..00000000 --- a/doc/source/user_guide.rst +++ /dev/null @@ -1,25 +0,0 @@ -User guide -========== - -User guides for the different ``pyansys`` packages can be found in their specific documentation. -The ``pyansys`` metapackage itself has no functionalities on its own. It is only a bundle of the -different public PyAnsys libraries that are compatible with a given Ansys Unified Install depending -on the version requested. - -**************************** -PyAnsys packages user guides -**************************** - -.. jinja:: project_context - - .. grid:: 3 - :gutter: 3 3 4 4 - - {% for project, metadata in projects['projects'].items() %} - {% if 'Tools' not in metadata['family'] %} - .. grid-item-card:: {{ metadata['name'] }} - :img-top: {{ metadata['thumbnail'] }} - :link: {{ metadata['documentation']['user_guide'] }} - :class-title: pyansys-card-title - {% endif %} - {% endfor %} \ No newline at end of file