Skip to main content

PenguinMol3D

PenguinMol3D is an open source Python3 package, which utilizes OpenGL python binding (https://pyopengl.sourceforge.net) for rendering of small compounds' 3D models.

Installation

Dependencies

  • numpy
  • rdkit
  • PyOpenGL
  • PyOpenGL_accelerate
  • glfw
  • Pillow

NOTE: Although dependencies are installed with package, on Windows OS Microsoft C++ 14 Build Tools are required to install PyOpenGL_accelerate

Usage

Initially, the RDKit Mol object is created from data in a file (e.g, MOL/SDF, MOL2 format) provided by user; the Mol object is further passed as an argument to the Mol3D class constructor, which generates a 3D model based on atom coordinates of the Mol object conformer. During the initialization stage (before running an event loop) user has to setup a scene by creating MolecularScene object and adding all necessary components like molecule and light sources as it is demonstrated in examples. As a drawing surface for rendering can be used any surface compatible with OpenGL; particularly, provided by such GUI libaries as GLFW (used in examples), PyGame, PyQt, PySide, wxPython, Tkinter + Togl widget, etc.

To check if package was installed correctly after installation enter:

Windows OS:

  • python -m PenguinMol3D.glfw_surface_example

Linux OS:

  • python3 -m PenguinMol3D.glfw_surface_example

PenguinMol3D currently supports two lighting models: Physically Based Lighting Model (default) and Blinn-Phong Lighting Model. To see examples of this two models enter:

Windows OS:

  • python -m PenguinMol3D.glfw_bpr_example
  • python -m PenguinMol3D.glfw_pbr_example
  • python -m PenguinMol3D.glfw_custom_material_example

Linux OS:

  • python3 -m PenguinMol3D.glfw_bpr_example
  • python3 -m PenguinMol3D.glfw_pbr_example
  • python3 -m PenguinMol3D.glfw_custom_material_example

Main folder also contains script, which can be used for small molecule visualization with predefined scene, to run it enter:

Windows OS:

  • python -m PenguinMol3D.display_molecule molecule_name.sdf

Linux OS:

  • python3 -m PenguinMol3D.display_molecule molecule_name.sdf

Release files for PenguinMol3D 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for PenguinMol3D 0.1.3
File Size Uploaded
PenguinMol3D-0.1.3.tar.gz 47.2 kB Details

Release files / PenguinMol3D-0.1.3.tar.gz

Download URL PenguinMol3D-0.1.3.tar.gz
Size 47.2 kB
Tags Source
SHA-256 checksum
How to use checksums
9bcbd66d7ec3ae35439bb1196b1abeabf29506498b4c2fe467da44fe097dbdf4
BLAKE2b-256 checksum
How to use checksums
a6130f26e9d1f9827852e71d9b7ad961af86c52a38d51ea05eb3d5b5012d1378
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.10.4

Release history Release notifications | RSS feed

This release

0.1.3 This release

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1.0

1 release file

0.0.9

1 release file

0.0.8

1 release file

0.0.7

1 release file

0.0.6

1 release file

0.0.5

1 release file

0.0.4

1 release file

0.0.3

1 release file

0.0.2

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page