Tags give the ability to mark specific points in history as being important
-
release_v1.2.0rc1
Release: release_v1.2.0rc18eae03e1 · ·## [1.2.0] - 2026-03-06 MolBar 1.2.0 is a major release that includes complete code refactoring, support for atropisomerism, and extensive test coverage. This version introduces atropisomerism support while reducing the computational cost by half compared to the previous version. The codebase has been completely reorganized for improved maintainability and modularity. A comprehensive test suite has also been added to ensure robustness and stability. ### Atropisomerism Detection Added automatic detection and idealization of atropisomeric structures through two independent classifiers: - **Steric Classifier**: Machine learning model that predicts rotational barriers around C-C, C-N, and N-N single bonds using Lennard-Jones potential energy scans. The model analyzes steric repulsion between substituents during bond rotation to identify bonds with high energy barriers. - **Electronic Classifier**: MPNN-based classifier that identifies bonds where electronic effects increase rotational barriers. Both classifiers allow MolBar to describe two structures as conformers if the rotational barriers of all dihedral angles are below 20 kcal/mol. However, if one dihedral angle exceeds 20 kcal/mol due to steric or electronic effects, the structures are described as distinct molecules. MolBar describes the absolute configuration for atropiomers. ### Code Refactoring Complete reorganization of the codebase for improved maintainability and modularity: - **New Module Structure**: - `molbar.molecule`: Introduced dedicated `Molecule` class to encapsulate atomic coordinates, elements, connectivity, bond orders, geometry classes, ring detection, and other molecular properties - `molbar.geometry`: Relocated geometry analysis functions (previously scattered across multiple modules) for VSEPR-based geometry classification and feature extraction - `molbar.topology`: Unified topology analysis including priorities, rings, and weighted bond order calculations - `molbar.constraints`: Separated constraint definitions for double bonds, allenes, rings, and general geometry into dedicated modules - `molbar.chirality`: Isolated chirality detection and chirality index calculation - `molbar.utils`: Consolidated utility functions including logger, vector operations, optimizer, and command-line tools - **Removed Modules**: Eliminated `molbar.molgraph`, `molbar.indices`, `molbar.helper`, `molbar.io`, `molbar.fortranlib` in favor of the new structure - **Improved Optimizer**: Implemented MolBar-specific optimizer with the `MolBarOpt` class. Supports both MolBar force field and custom energy functions with analytical derivatives. ### Testing Added comprehensive test suite with 55 test files: - Unit tests for all major components: topology, geometry, chirality, constraints, barcode calculation - Integration tests for end-to-end workflows - Dedicated atropisomerism tests with reference structures - Regression tests for edge cases and numerical stability - Tests for allene, double bond, ring, and geometry constraints - Parser, printer, and utility function tests ### New Utilities Added new command-line tools for molecular analysis: - `moldiff`: Compare two molecular structures and identify differences (stereoisomerism, conformers, enantiomers, atropisomers) - `molopt`: Geometry optimization using MolBar force field or custom functions - `mbslice`: Extract specific layers from MolBar strings for analysis - `fragcount`: Count molecular fragments in structures ### Error Handling and Logging Improved error handling with custom exception hierarchy: - Introduced specific exceptions: `BarcodeError`, `InvalidInputError`, `CalculationError`, `MoleculeError`, `MolBarDifferenceError` - Added structured logging system with configurable log levels, file output, and console control - Input validation for all public API functions with clear error messages ### API Changes - **Breaking Change**: Removed `molbar.idealize` module (geometry idealization is now integrated into the main workflow) - **Additive Change**: New `return_data` parameter provides access to intermediate calculation data including priorities, geometry classes, constraint information, and topography details - **Additive Change**: `get_molbar_from_coordinates` and related functions now support `debug` parameter for detailed logging - **Additive Change**: Command-line interface supports new flags: `--debug`, `--log-file`, `--no-console` ### Performance Improvements - Optimized connectivity matrix operations using NumPy broadcasting - Replaced recursive graph traversal with breadth-first search using NumPy arrays - Vectorized bond order and geometry calculations - Reduced memory allocation in constraint generation ### Build System - Fixed source distribution to include CMakeLists.txt (resolves compilation failure when installing from tarball via pip) - Updated MANIFEST.in to properly include all Fortran source files and CMake configuration ### Documentation - Added comprehensive docstrings following NumPy style guide - Included type hints for all public functions - Added copyright headers with SPDX license identifiers to all modules The Python versions supported by this release are 3.8-3.14.
-
-
-
-
-
-
-