Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/build_documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ jobs:
- name: Sphinx build
env:
PYTHON_PACKAGE_MANAGER: ${{steps.environment.outputs.ppm}}
PYTHONPATH: ${{ github.workspace }}
run: |
set -euxo pipefail
$PYTHON_PACKAGE_MANAGER activate queens
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@ PROBLEM TYPE:
PROBLEMTYPE: "Structure"
IO:
OUTPUT_SPRING: true
STRUCT_STRESS: Cauchy
IO/RUNTIME VTK OUTPUT:
INTERVAL_STEPS: 1
IO/RUNTIME VTK OUTPUT/STRUCTURE:
OUTPUT_STRUCTURE: true
DISPLACEMENT: true
STRESS_STRAIN: true
STRUCTURAL DYNAMIC:
INT_STRATEGY: "Standard"
RESEVERYERGY: 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"source": [
"# Define some paths\n",
"from pathlib import Path\n",
"from utils import find_repo_root\n",
"from tutorials.utils import find_repo_root\n",
"\n",
"home = Path.home()\n",
"NOTEBOOK_DIR = Path.cwd()\n",
Expand Down Expand Up @@ -277,7 +277,7 @@
"source": [
"# This is just needed for some nice plots\n",
"\n",
"from utils import plot_results\n",
"from plot_results import plot_results\n",
"if pyvista_available:\n",
" plotter = pv.Plotter()\n",
" plot_results(\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# should have received a copy of the GNU Lesser General Public License along with QUEENS. If not,
# see <https://www.gnu.org/licenses/>.
#
"""Data for tutorial 4."""
"""Data for tutorial 3."""
import numpy as np

experimental_elementwise_cauchy_stress = np.array(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,8 @@
# should have received a copy of the GNU Lesser General Public License along with QUEENS. If not,
# see <https://www.gnu.org/licenses/>.
#
"""Utility functions for tutorial 4."""
"""Plotting functions for tutorial 3."""
import os
from pathlib import Path

os.environ["PYVISTA_OFF_SCREEN"] = "true"
os.environ["VTK_DEFAULT_RENDER_WINDOW_OFFSCREEN"] = "1"
Expand Down Expand Up @@ -55,18 +54,3 @@ def plot_results(
(0.0, 0.0, 0.2749999999999999),
(-0.97637930372977, -0.08995062285804697, 0.19644933366041056),
]


def find_repo_root(start: Path) -> Path:
"""Find the repository root by going upwards from a starting directory.

Args:
start (Path): Starting directory to begin the upward search.

Returns:
Path: Path to the detected repository root (containing ``pyproject.toml``).
"""
for p in [start, *start.parents]:
if (p / "pyproject.toml").exists():
return p
raise RuntimeError(f"Could not find repo root from {start}")
Loading
Loading