Skip to content
John Hoffer edited this page Mar 12, 2018 · 12 revisions

For Clients of the Server

For Developers of the Server

  • You'll first want to see Keywords page
    • The Keyword Structures show which NAMES and VALUES all modules get and set.
  • For a layout of the AccessLayer subclasses, check back by the end of March.
    • API This fully-featured handler can prepare InfoQuery and DataQuery.
    • OCP This more standard handler will prepare DataQuery like the API.
  • To get started check out the guides to each of the three QueryLayer subclasses
    • InfoQuery (This takes dictionary requests. It's ready for a DataQuery)
    • DataQuery (This takes volume requests. It's ready for many TileQuery)
    • TileQuery (This takes small requests. It's ready for the ImageLayer)

For serving index.json files

Let's assume that:

  • You have an image volume at /n/TEST/2018_01_01/em.json
  • You have a segmented volume at /n/TEST/2018_01_01/id.json
    • This volume starts at z=80 relative to the image volume

Before running bfly, save this file as ~/.rh-config.yaml

bfly:
  log-level: WARNING
  db-type: Nodb
  experiments:
  - name: TEST
    samples:
    - name: '2018_01_01'
      datasets:
          - name: '1x1y1z'
            channels:
            - name: 'em'
              path: /n/TEST/2018_01_01/em.json
            - name: 'id'
              offset: [80, 0, 0]
              path: /n/TEST/2018_01_01/id.json

For making mesh files

Let's assume that the butterfly repository is /n/USER/BFLY

Save this file as mesh.yaml and run slyml mesh.yaml from within the 3DXP directory.

# slyml.py v2.2
#
Misc:
    - &mesh_json-0
      Slurm: ./SLURM/one.sbatch
      python: ./PYTHON/json_index.py
      args: "{OUT_3D}/pre"
    - &h5_mesh-0
      Slurm: ./SLURM/many.sbatch
      python: ./PYTHON/all_stl.py
      args: "{OUT}/id.h5 {OUT_3D} {MESH_FMT} -f %d:{MESH_RES} -b {N_BOX} -l {LIST}"
      Runs: "{N_BOX}**3"
    - &boss_h5-id
      Slurm: ./SLURM/one.sbatch
      python: ./PYTHON/conversion/tif2hd.py
      args: "{OUT}/tif/id {OUT}/id.h5"
      Inputs:
          CROP: "-s {ID_Z}:{ID_YX}:{ID_YX}"
      Needs:
          args: "{BOSS_ID} -o {OUT}/tif/id {CROP} {ID_OFF} -f tif"
          python: ./PYTHON/conversion/boss2stack.py
          Slurm: ./SLURM/many.sbatch
          Runs: 40
Main:
    <<: *h5_mesh-0
    Constants:
        ID_Z: 3
        ID_YX: 5
        N_BOX: 2
        ID_OFF: "-d 0:0:0"
        LIST: "1-10000"
        MESH_RES: 0
    Needs: *boss_h5-id
    For: *mesh_json-0
Default:
    Constants:
        BOSS_ID: /n/TEST/2018_01_01/id.json
        OUT_ROOT: /n/USER/BFLY/bfly/static/
        EXPERIMENT: TEST
        SAMPLE: "2018_01_01"
        DATASET: "1x1y1z"
        MESH_FMT: "--pre --xyz"
        MESH_RUN: 10
        ANISO: 7.5
    Inputs:
        OUT: "{OUT_ROOT}/tmp/{EXPERIMENT}::{SAMPLE}::{DATASET}/id"
        OUT_3D: "{OUT_ROOT}/mesh/{EXPERIMENT}::{SAMPLE}::{DATASET}/id"
    Logs: "./LOGS/{EXPERIMENT}/{SAMPLE}/{DATASET}"
    Workdir: "git rev-parse --show-toplevel"
    Exports: [python, args]
    Flags: [partition]
    partition: general

Version 2

Version 1

Clone this wiki locally