navigate Logo

Getting Started

  • Computer Considerations
  • Computer Power Configuration
  • Software Installation
  • Launching Navigate
  • Configuring Navigate
  • Acquiring Data
  • Smart Acquisition Routines

User Guide

  • Supported Hardware
  • Supported File Formats
  • User Interface Walkthrough
  • Setting Up a Microscope
  • Acquiring Data
  • Case Studies

Development

  • Contributing Guidelines
  • Developer Install
  • Software Architecture
  • Developer Architecture Concepts
  • Feature Container
  • REST API
  • Plugin Architecture
  • Adding New Hardware

Troubleshooting & Known Issues

  • Troubleshooting
  • Known Issues

Plugins

  • navigate Plugin Template
  • navigate Confocal Projection
  • navigate at Scale
  • navigate Constant Velocity Acquisition
  • navigate MMCore
  • navigate ilastik Server
  • navigate Photoactivation

Reference

  • Implemented Microscopes
  • Software API
    • navigate.config
    • navigate.controller
    • navigate.controller.configurator
    • navigate.log_files
    • navigate.model
      • navigate.model.analysis
      • navigate.model.concurrency
        • navigate.model.concurrency.concurrency_tools
      • navigate.model.data_sources
      • navigate.model.device_startup_functions
      • navigate.model.devices
      • navigate.model.features
      • navigate.model.metadata_sources
      • navigate.model.microscope
      • navigate.model.model
      • navigate.model.plugins_model
      • navigate.model.resolution_change
      • navigate.model.waveforms
    • navigate.tools
    • navigate.view
navigate
  • Software API
  • navigate.model
  • navigate.model.concurrency
  • navigate.model.concurrency.concurrency_tools
  • navigate.model.concurrency.concurrency_tools.CustodyThread
  • View page source

navigate.model.concurrency.concurrency_tools.CustodyThread

class navigate.model.concurrency.concurrency_tools.CustodyThread(first_resource=None, group=None, target=None, name=None, args=(), kwargs=None)

Bases: ResultThread

Threads that can access shared resources in the order they were launched.

See the docstring at the top of this module for examples.

__init__(first_resource=None, group=None, target=None, name=None, args=(), kwargs=None)

This constructor should always be called with keyword arguments. Arguments are:

group should be None; reserved for future extension when a ThreadGroup class is implemented.

target is the callable object to be invoked by the run() method. Defaults to None, meaning nothing is called.

name is the thread name. By default, a unique name is constructed of the form “Thread-N” where N is a small decimal number.

args is a list or tuple of arguments for the target invocation. Defaults to ().

kwargs is a dictionary of keyword arguments for the target invocation. Defaults to {}.

If a subclass overrides the constructor, it must make sure to invoke the base class constructor (Thread.__init__()) before doing anything else to the thread.

Methods

__init__([first_resource, group, target, ...])

This constructor should always be called with keyword arguments.

get_result([timeout])

Either returns a value or raises an exception.

run()

Method representing the thread's activity.

start()

Start the thread's activity.

get_result(timeout=None)

Either returns a value or raises an exception.

Optionally accepts a timeout in seconds. If thread has not returned after timeout seconds, raises a TimeoutError.

run()

Method representing the thread’s activity.

You may override this method in a subclass. The standard run() method invokes the callable object passed to the object’s constructor as the target argument, if any, with sequential and keyword arguments taken from the args and kwargs arguments, respectively.

start()

Start the thread’s activity.

It must be called at most once per thread object. It arranges for the object’s run() method to be invoked in a separate thread of control.

This method will raise a RuntimeError if called more than once on the same thread object.

Previous Next

© Copyright 2026, Dean Lab, UT Southwestern Medical Center.