Skip to main content

openvisuspy

Project description

Instructions

Important:

Installation

In Windows:

set PATH=c:\Python310;%PATH%
where python

python.exe -m venv .venv
.venv\Scripts\activate

python.exe -m pip install --upgrade pip
python.exe -m pip install -r requirements.txt

# install the latest version of OpenVisus
python.exe -m pip install --upgrade OpenVisusNoGui openvisuspy

In MacOs/Linux:

python3 -m venv .venv
source .venv/Scripts/activate
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements.txt

# install the latest version of OpenVisus
python3 -m pip install --upgrade OpenVisusNoGui openvisuspy

Dashboards

In Windows:

.venv\Scripts\activate
python.exe -m panel serve ./app --dev --args ./json/dashboards.json

In MacOs/Linux:

source .venv/bin/activate
python.exe -m panel serve ./app --dev --args ./json/dashboards.json

Notebooks

In Windows:

.venv\Scripts\activate
jupyter lab ./notebooks

In MacOs/Linux:

source .venv/bin/activate
jupyter lab ./notebooks

Important: if Panel is not working you may have to do:

pskill python
jupyter nbconvert --clear-output --inplace notebooks/test-panel.ipynb  
jupyter trust notebooks/test-panel.ipynb  

Docker Compose

Create an .env file with a token:

cat <<EOF > .env
NSDF_TOKEN=whatever-but-secure
EOF
# sudo docker-compose up chess1_service
# sudo docker-compose up chess2_service
# sudo docker-compose up jupyterlab_service

sudo docker-compose up 

You can check if it's working going to any of the URL:

Deploy using ansible

Create an ``./inventory.ini` file. For example

[all:vars]
ansible_ssh_connection=ssh 
ansible_ssh_user=root
ansible_ssh_private_key_file=~/.ssh/id_rsa

[my_vps]
127.0.0.1

Run the ansible playbooks:

# this is needed for WSL2
export ANSIBLE_CONFIG=${PWD}/ansible.cfg

# check connectivity
ansible all -m ping

# Run single command
ansible --become-user root --become all -m shell -a 'docker ps'

# Clean up notebooks
for it in $(find ./notebooks/*.ipynb) ; do
  jupyter nbconvert --clear-output --inplace ${it}
  jupyter trust ${it}
done

#   --tags "configuration,packages"
#   --limit=<hostname>
#   -l <group-name>
#   -vvv
ansible-playbook ./ansible/00-setup-node.yml 
ansible-playbook ./ansible/01-benchmark.yml --verbose
ansible-playbook ./ansible/02-remove-all-containers.yml 
ansible-playbook ./ansible/03-precache-data.yml -vvv --limit hetzner
ansible-playbook ./ansible/04-run.yml 

Test Volume rendering

python test/test-pyvista.py
python test/test-vtkvolume.py 

Debug openvisuspy

Debug mode in Windows

.venv\Scripts\activate

set PATH=c:\Python310;%PATH%

set BOKEH_ALLOW_WS_ORIGIN=*
set BOKEH_LOG_LEVEL=debug
set VISUS_CPP_VERBOSE=1
set VISUS_NETSERVICE_VERBOSE=1
set VISUS_VERBOSE_DISKACCESS=0
set VISUS_CACHE=c:/tmp/visus-cache

set PYTHONPATH=C:\projects\OpenVisus\build\RelWithDebInfo;.\src

# dashboards
python.exe -m panel serve ./app --dev --args ./json/dashboards.debug.json

# jupyter lab
python.exe -m jupyter lab notebooks/ov-dashboards.ipynb

python.exe -m panel serve ./app --dev --args "https://atlantis.sci.utah.edu/mod_visus?action=readdataset&dataset=chess-intro&cached=arco" --probe

Deploy binaries

./scripts/new_tag.sh

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

openvisuspy-1.0.64-py3-none-any.whl (3.8 MB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page