Generic SeaRay Installation¶
Install Miniforge3¶
The pyopencl developers recommend using Miniforge as opposed to Anaconda or Miniconda.
Uninstall miniconda/anaconda, or else be prepared to add path specifiers from time to time
Internet search for
miniforgeFollow installation guide for your platform
conda update condaconda initIf you want to use PowerShell run
conda init powershell
Install Drivers¶
If you are using Windows:
AMD — install specific drivers for the video card
NVIDIA — install CUDA developer tools
Intel CPU — install Intel CPU Runtime for OpenCL
If you are using Mac/Linux:
CPU — no action required
NVIDIA — install CUDA developer tools
Environment and Basic Packages¶
Choose a name for your environment, denoted
NAMEconda create -n NAME pyopencl scipy matplotlib jupyter ipympl pillow pytest python=3.11You may be able to use a later python version
As of this writing there is an issue with OpenSSL on Windows, it may help to force miniforge to use a specific version, e.g., add
openssl=3.2.0to all install commands.
If you are using Mac or Linux,
conda install poclconda activate NAMEThis command puts you in an isolated conda environment. This command must be issued each time you open a new terminal window, in order to use the environment.
Getting SeaRay Components¶
To copy the SeaRay components to your local computer perform the following procedure:
Install
gitif necessary using your favorite package manager or other methodNavigate to the directory where you want to install SeaRay (you don’t need to make an enclosing directory).
git clone https://github.com/USNavalResearchLaboratory/searay.git- Checkout a stable version
git tag --listdisplays tagged commits.Select a tag without a letter suffix for the highest stability.
git checkout vers, whereversis the selected tag.
If you like you can give the SeaRay root directory another name, we will call it
raysrootfrom now on.
Optional Components¶
- If you want the nicest looking plot labels you may want to install a TeX distribution.
Search internet to find instructions for your operating system.
Uncomment the line
mpl.rcParams['text.usetex'] = Truenear the top ofplotter.py.
- If you want the best 3D plots you may want to install
mayavi Activate your environment.
conda install mayaviThe plotter automatically senses its presence
- If you want the best 3D plots you may want to install