Skip to content

Commit

Permalink
Merge pull request #18 from kieran-mackle/development
Browse files Browse the repository at this point in the history
Prepare for readthedocs deployment
  • Loading branch information
kieran-mackle authored Jan 2, 2024
2 parents 6fc3733 + e033905 commit b116dae
Show file tree
Hide file tree
Showing 5 changed files with 50 additions and 65 deletions.
29 changes: 29 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the OS, Python version and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.11"

# Build documentation in the "docs/" directory with Sphinx
sphinx:
configuration: docs/source/conf.py

# Optionally build your docs in additional formats such as PDF and ePub
formats:
- pdf

# Optional but recommended, declare the Python requirements required
# to build your documentation
# See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
python:
install:
- requirements: docs/source/requirements.txt
- method: pip
path: .
34 changes: 3 additions & 31 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,40 +5,12 @@ defined by hyperpatches. Check out the
[hangar](docs/source/hangar.md) for some examples.


## Getting Started
## Installation

### Prerequisites
Hypervehicle relies on the [GDTK](https://github.com/gdtk-uq/gdtk) geometry
package. Note that a full install of GDTK is not required. Instead, you can simply do a
[sparse checkout](https://stackoverflow.com/questions/600079/how-do-i-clone-a-subdirectory-only-of-a-git-repository)
of the relevant files, using the commands below.
To install `hypervehicle`, use the command below.

```
mkdir gdtk
cd gdtk/
git init
git remote add -f origin https://github.com/gdtk-uq/gdtk.git
git config core.sparseCheckout true
echo "src/lib/" >> .git/info/sparse-checkout
git pull origin master
cd src/lib
python3 -m pip install -e ./
cd ../../../
```

#### PyMesh

Having [PyMesh](https://github.com/PyMesh/PyMesh) installed can greatly enhance the capabilities
offered by `HyperVehicle`. However, it can be difficult to install. Troubleshooting
guide coming soon.


### Installation

To install `hypervehicle` from source, use the command below.

```
pip install git+https://github.com/kieran-mackle/hypervehicle
pip install hypervehicle
```

## Usage
Expand Down
45 changes: 11 additions & 34 deletions docs/source/getting-started.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,8 @@
# Getting Started with HyperVehicle

## Dependencies

### GDTK
<tt>HyperVehicle</tt> depends on the
[GDTK](https://github.com/gdtk-uq/gdtk) Python package for its geometric toolkit.
Note that a full install of GDTK is not required. Instead, simply do a
[sparse checkout](https://stackoverflow.com/questions/600079/how-do-i-clone-a-subdirectory-only-of-a-git-repository)
of the relevant files, using the commands below.

```
mkdir gdtk
cd gdtk/
git init
git remote add -f origin https://github.com/gdtk-uq/gdtk.git
git config core.sparseCheckout true
echo "src/lib/" >> .git/info/sparse-checkout
git pull origin master
cd src/lib
python3 -m pip install .
cd ../../../
```

## Optional Dependencies

### PyMESH

To access more advanced features of <tt>HyperVehicle</tt>, such as compeonent mesh merging
and cleaning, [PyMesh](https://github.com/PyMesh/PyMesh) is required. You do not need to install
this to use <tt>HyperVehicle</tt>, but it can come in handy, especially when extracting
sensitivities for multi-component geometries.


## Installation


### Installation from PyPi
### Installation from PyPI

```
pip install hypervehicle
Expand All @@ -57,3 +24,13 @@ ready to go, run the command below.
```
python3 -m pytest tests/
```


## Optional Dependencies

### PyMESH

To access more advanced features of <tt>HyperVehicle</tt>, such as compeonent mesh merging
and cleaning, [PyMesh](https://github.com/PyMesh/PyMesh) is required. You do not need to install
this to use <tt>HyperVehicle</tt>, but it can come in handy, especially when extracting
sensitivities for multi-component geometries.
6 changes: 6 additions & 0 deletions docs/source/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
sphinx
furo
sphinx_copybutton
myst_parser
sphinx_inline_tabs
Jinja2<3.1
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ def get_version(rel_path):
"tqdm >= 4.64.1",
"multiprocess >= 0.70.14",
"pymeshfix >= 0.16.2",
"gdtk @ git+https://[email protected]/gdtk-uq/gdtk.git#subdirectory=src/lib",
],
extras_require={
"dev": dev,
Expand Down

0 comments on commit b116dae

Please sign in to comment.