navigate Logo

Getting Started

  • Quick Start Guide
  • Software Installation
  • I Want To…

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
  • Feature Container
  • REST-API
  • Plugin Architecture

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.log_files
    • navigate.model
    • navigate.tools
      • navigate.tools.common_dict_tools
        • navigate.tools.common_dict_tools.update_nested_dict
        • navigate.tools.common_dict_tools.update_stage_dict
      • navigate.tools.common_functions
      • navigate.tools.decorators
      • navigate.tools.file_functions
      • navigate.tools.image
      • navigate.tools.linear_algebra
      • navigate.tools.main_functions
      • navigate.tools.multipos_table_tools
      • navigate.tools.sdf
      • navigate.tools.slicing
      • navigate.tools.waveform_template_funcs
      • navigate.tools.xml_tools
    • navigate.view
navigate
  • Software API
  • navigate.tools
  • navigate.tools.common_dict_tools
  • navigate.tools.common_dict_tools.update_nested_dict
  • View page source

navigate.tools.common_dict_tools.update_nested_dict

navigate.tools.common_dict_tools.update_nested_dict(d, find_func, apply_func)

Update a nested dictionary by applying a function to a value

Loops through a nested dictionary and if find_func() conditions are met, run apply_func on that key.

TODO: It might be nice to make this non-recursive.

Parameters:
  • d (dict) – Dictionary to be updated

  • find_func (func) – Accepts key, value pair and matches a condition based on these. Returns bool.

  • apply_func (func) – Accepts a value returns the new value.

Returns:

d2 – An version of d, updated according to the passed functions.

Return type:

dict

Previous Next

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