<jupyter_start><jupyter_text>Create a static viewerA static viewer is a brain viewer that exists permanently on a filesystemThe viewer is stored in a directory that stores html, javascript, data, etcThe viewer directory must be hosted by a server such as nginx<jupyter_code>import cortex

import numpy as np
np.random.seed(1234)

# gather data Volume
volume = cortex.Volume.random(subject='S1', xfmname='fullhead')

# select path for static viewer on disk
viewer_path = '/path/to/store/viewer'

# create viewer
cortex.webgl.make_static(outpath=viewer_path, data=volume, recache=True)

# a webserver such as nginx can then be used to host the static viewer<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.07153284671532846, 'fraction_numerical': 0.0072992700729927005, 'mean_word_length': 5.86, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '289138', 'license': 'BSD-2-Clause', 'n_tokens_mistral': 223, 'n_tokens_neox': 203, 'n_words': 79, 'path': 'example-notebooks/webgl/static.ipynb', 'repo_name': 'VisionandCognition/pycortex', 'size': '685'}