Skip to content

v0.5.0

Latest

Choose a tag to compare

@Lookatator Lookatator released this 27 May 15:18
· 108 commits to main since this release
f06dda3

Link to Release PR - #238

🛠️ Core Framework Improvements

Custom Repertoire Integration (#222)

  • Allow MAPElites to be built with any repertoire by passing custom repertoire init functions
  • Default behavior maintained with MapElitesRepertoire.init
  • Enhanced flexibility for custom repertoire implementations

MAPElites Repertoire Enhancement (#211)

  • Enhanced MAPElitesRepertoire to store any kind of information through improved extra_scores handling
  • Standardized extra scores management across all repertoire classes with keys_extra_scores parameter
  • Added filter_extra_scores method to filter extra scores based on keys
  • Moved observations from dedicated fields to extra_scores storage

Ask/Tell Interface (#221)

  • New user-facing ask/tell interface for more flexible algorithm interaction
  • Added init_ask_tell function for initialization without scoring functions
  • Refactored update functions to use ask/tell internally, reducing code duplication

🔄 Major Refactoring & Architecture Changes

Selector System Overhaul (#209)

  • New unified selection interface through the Selector abstraction for improved modularity and extensibility
  • Introduced UniformSelector and MOMEUniformSelector implementations
  • Selectors now return full sub-repertoires instead of just genotypes, eliminating the need for multiple sampling functions
  • Default selection behavior integrated into repertoire classes

Brax Environment Structure Reorganization (#236)

  • Complete restructuring of Brax-related code from /environments to /tasks/brax with proper versioning
  • Added Brax v2 support alongside existing Brax v1
  • Improved environment handling and version management

Code Organization (#200, #204)

  • Moved cmaes.py from core to baselines for better module organization

🔧 Code Quality & Standards

Terminology Standardization (#190)

  • Unified descriptor naming from mixed "bd", "BD", "behavior_descriptor" to consistent "descriptor"
  • Stopped returning random keys following JAX best practices
  • Renamed all random_key parameters to key
  • Removed deprecated Brax scoring functions
  • Standardized unused parameter naming with underscore prefix

JIT Compilation Cleanup (#232)

  • Removed individual jax.jit decorators from internal functions for more user coding flexibility
  • Improved function signatures

JAX Modernization (#195)

  • Updated to new-style JAX random keys (jax.random.key instead of jax.random.PRNGKey)
  • Full compliance with JAX JEP 9263 typed keys specification

⚡ Performance & Memory Optimizations

VRAM Optimization (#224)

  • Significant memory improvements in PGA and DCRL algorithms
  • Off-spring PG mutations now share mini-batches, reducing memory usage
  • Step-by-step transition sampling in both "emit_pg" and "state_update"
  • Simplified function structure and combined training/update operations
  • New scan_actor_critic_training function for efficient Actor-Critic loops

🔍 Quality Assurance

Automated Spell Checking (#194)

  • Added codespell pre-commit hook to catch typos automatically
  • Fixed existing typos throughout codebase
  • Updated pre-commit configuration with latest package versions

Updated example notebooks with better parameter handling for NSGA-II and SPEA2 (#231)

  • Fixed batch size parameters to use population_size by default for genetic algorithms

📊 Metrics & Analysis Features

Uncertainty Domain Support (#186)

  • New reevaluation functions in qdax/utils/uncertain_metrics.py
  • Compute corrected archives for uncertain domains
  • Comprehensive test coverage for uncertainty metrics

Enhanced Visualization (#233)

  • Custom x-axis labels in plot_map_elites_results
  • Defaults to "Environment steps" with backward compatibility

Metrics Initialization (#214)

  • Return metrics after repertoire initialization for better monitoring

🧹 Cleanup & Maintenance

Simplified Interface (#225)

  • Removed save and load methods from repertoire classes
  • Users can now use custom serialization methods like pickle or orbax
  • Reduced maintenance burden for new repertoire types

Package Configuration Modernization (#213)

  • Migrated from setup.py to pyproject.toml for modern Python packaging standards

Fixed indexing in UnstructuredRepertoire (#185)

  • better handling of NaN descriptors

Legacy spring support (#226)

  • Legacy spring support for Brax v1 with backward compatibility boolean flag