Skip to content

Commit 44b289d

Browse files
HaoZekeamritagos
andcommitted
DOC: Update documentation for conda
Co-authored-by: Amrita Goswami <[email protected]>
1 parent 4f39638 commit 44b289d

File tree

1 file changed

+39
-2
lines changed

1 file changed

+39
-2
lines changed

README.md

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
the data-sets (trajectories) <a
2222
href="https://figshare.com/projects/d-SEAMS_Datasets/73545">from figshare</a>.
2323

24-
\warning **If** you are unwilling to use the `nix` build system, then **please note** that you must manage the dependencies MANUALLY, including the compiler versions.
24+
\warning **If** you are unwilling to use the `nix` build system, then **please note** that you must manage the dependencies MANUALLY, including the compiler versions. Optionally, use the provided `conda` environment.
2525

2626
# Citation
2727

@@ -49,15 +49,44 @@ The corresponding `bibtex` entry is:
4949
url={https://doi.org/10.1021/acs.jcim.0c00031}
5050
}
5151

52-
# Compilation with Nix
52+
# Compilation
5353

5454
We use a deterministic build system to generate both bug reports and uniform
5555
usage statistics. This also handles the `lua` scripting engine.
5656

5757
\note The lua functions are documented on the [on the API Docs](https://docs.dseams.info/md_markdown_luafunctions)
5858

59+
We also provide a `conda` environment as a fallback, which is also recommended for MacOS users.
60+
5961
## Build
6062

63+
### Conda
64+
65+
Although we strongly suggest using `nix`, for MacOS systems, the following
66+
instructions may be more suitable. We will assume the presence of [micromamba](https://mamba.readthedocs.io/en/latest/installation.html):
67+
68+
```bash
69+
micromamba create -f environment.yml
70+
micromamba activate dseams
71+
```
72+
73+
Now the installation can proceed.
74+
75+
\note we do not install a new version of `cmake` within the `conda` environment because of conflicts with `lua`
76+
77+
```bash
78+
mkdir build
79+
cd build
80+
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_EXPORT_COMPILE_COMMANDS=YES -DCMAKE_INSTALL_PREFIX:PATH=$CONDA_PREFIX ../
81+
make -j$(nproc)
82+
make install
83+
```
84+
85+
We have opted to install into the `conda` environment, if this is not the
86+
intended behavior, use `/usr/local` instead.
87+
88+
### Nix
89+
6190
Since this project is built with `nix`, we can simply do the following from the
6291
root directory (longer method):
6392

@@ -87,6 +116,14 @@ nix-env -if . # Required
87116
yodaStruct -c lua_inputs/config.yml
88117
```
89118

119+
### Usage
120+
121+
Having installed the `yodaStruct` binary and library, we can now use it.
122+
123+
```bash
124+
yodaStruct -c lua_inputs/config.yml
125+
```
126+
90127
\note The paths in the `.yml` should be **relative to the folder from which the binary is called**.
91128

92129
If you're confused about how to handle the relative paths, run the command `yodaStruct -c lua_inputs/config.yml` in the top-level directory, and set the paths relative to the top-level directory. This is the convention used in the examples as well.

0 commit comments

Comments
 (0)