python_molecular_editor

MoleditPy — A Python Molecular Editor

DOI Powered by RDKit

MoleditPy is a cross-platform, intuitive molecular editor built in Python. It provides a seamless workflow for drawing 2D molecular structures, visualizing them in 3D, and performing interactive geometric manipulations. Its powerful editing and export capabilities make it an ideal tool for preparing input files for DFT calculation software.

Author: HiroYokoyama License: GPL-v3 Repository: https://github.com/HiroYokoyama/python_molecular_editor


—–

Overview

This application combines a modern GUI built with PyQt6, powerful cheminformatics capabilities from RDKit, and high-performance 3D rendering by PyVista to provide an easy-to-use tool for drawing and visually inspecting molecular structures.

Key Features

 Please refer to the user manual for details.

1. 2D Drawing and Editing

2. 3D Visualization and Advanced Editing

3. Analysis and Export

Installation and Execution

For detailed instructions, please refer to the project Wiki. A Docker version is also available. A Windows installer is also distributed.

Requirements

PyQt6, RDKit, NumPy, PyVista, pyvistaqt, openbabel

Installation

  1. Install the Package This will automatically install the correct moleditpy (for Win/Mac) or moleditpy-linux (for Linux) as a dependency.

    pip install moleditpy-installer
    
  2. Create the Shortcut After installation, run this command to create the shortcut in your application menu (e.g., Start Menu or Applications folder).

    moleditpy-installer
    

Running the Application

moleditpy

(Note: The first launch may take some time while libraries like RDKit are initialized.)

Keyboard Shortcuts

Key Action Notes
1/2/3 Change bond order Single/Double/Triple bond
W/D Change to stereochemical bond Wedge / Dash bond
Delete/Backspace Delete item(s) Deletes selected or hovered items
. Toggle radical Cycles through 0, 1, and 2 radicals
+/- Increase/Decrease charge Changes formal charge
C, N, O, etc. Change atom symbol Applies to atom under cursor
4 Place benzene ring One-shot placement on atom/bond
Space Toggle select mode / Select all  
Ctrl+J Perform 2D optimization (Clean Up)  
Ctrl+K Perform 2D-to-3D conversion  
Ctrl+L Perform 3D structure optimization  

Technical Details

License

This project is licensed under the GNU General Public License v3.0 (GPL-v3). See the LICENSE file for details.


MoleditPy — A Python Molecular Editor

MoleditPyは、Pythonで構築されたクロスプラットフォームかつ直感的な分子エディターです。2Dでの分子描画から3D構造の可視化・編集、さらにはインタラクティブな幾何学的操作まで、シームレスなワークフローを提供します。その強力な編集機能とエクスポート機能により、DFT計算ソフトウェアのインプット作成に最適なツールです。

作者: HiroYokoyama ライセンス: GPL-v3 リポジトリ: https://github.com/HiroYokoyama/python_molecular_editor


概要

このアプリケーションは、PyQt6によるモダンなGUI、RDKitによる強力な化学計算、PyVistaによる高性能な3Dレンダリングを組み合わせ、分子構造の描画と視覚的な確認を容易にするツールです。

主な機能

詳細は、ユーザーマニュアルを参照してください。

1. 2D描画と編集

2. 3D可視化と高度な編集

3. 解析とエクスポート

インストールと実行

詳細な手順については、プロジェクトのWikiを参照してください。Docker版も利用可能です。Windows向けインストーラーも使用できます。

必要ライブラリ

PyQt6, RDKit, NumPy, PyVista, pyvistaqt, openbabel

インストール

  1. パッケージのインストール このコマンドを実行すると、お使いのOS(Windows/macOSまたはLinux)に適した moleditpy 本体が自動的にインストールされます。

    pip install moleditpy-installer
    
  2. ショートカットの作成 インストール後、このコマンドを実行すると、アプリケーションメニュー(スタートメニューやアプリケーションフォルダなど)にショートカットが作成されます。

    moleditpy-installer
    

アプリケーションの起動

moleditpy

(注:初回起動時は、RDKitなどのライブラリの初期化のため、起動に時間がかかる場合があります。)

キーボードショートカット

キー 操作 補足
1/2/3 結合次数を変更 単結合/二重結合/三重結合
W/D 立体化学結合に変更 Wedge / Dash 結合
Delete / Backspace アイテムの削除 選択またはカーソル下のアイテムを削除
. ラジカルをトグル 0, 1, 2ラジカルを循環
+/- 電荷を増減 形式電荷の変更
C, N, O など 原子記号を変更 カーソル下の原子に適用
4 ベンゼン環の配置 カーソル下の原子/結合にワンショットで配置
Space 選択モード切替 / 全選択  
Ctrl+J 2D最適化を実行  
Ctrl+K 3D変換を実行  
Ctrl+L 3D最適化を実行  

技術的な仕組み

ライセンス

このプロジェクトは GNU General Public License v3.0 (GPL-v3) のもとで公開されています。詳細は LICENSE ファイルを参照してください。