Skip to content

Instantly share code, notes, and snippets.

View samoturk's full-sized avatar

Samo Turk samoturk

View GitHub Profile
@samoturk
samoturk / PKGBUILD
Created October 30, 2014 16:12
RDKit release 2014_09_1 Arch Linux PKGBUILD python3
# Maintainer: Samo Turk <samo.turk@gmail.com>
pkgname=rdkit
_pkgname=RDKit
pkgver=2014_09_1
pkgrel=1
pkgdesc="RDKit - A collection of cheminformatics and machine-learning software written in C++ and Python."
arch=("i686" "x86_64")
url="http://rdkit.org/"
license=('New BSD License')
depends=( 'bison' 'boost' 'boost-libs' 'cmake' 'flex' 'python' 'python-numpy' 'sqlite3' )
@samoturk
samoturk / RDKit-2014_09_1.spec
Created October 30, 2014 12:41
RDKit release 2014_09_1 OpenSuse SPEC file
Name: rdkit
Version: 2014_09_1
Release: 0
License: BSD-3-Clause
BuildRoot: %{_tmppath}/%{name}-Release_%{version}-build
BuildRequires: gcc-c++ flex bison sqlite3-devel python-numpy-devel
BuildRequires: python-devel boost-devel cmake fdupes libopenbabel-devel
Group: Development/Libraries/C and C++
Summary: A collection of cheminformatics and machine-learning software
Url: http://rdkit.org
@samoturk
samoturk / PKGBUILD
Created October 30, 2014 12:39
RDKit release 2014_09_1 Arch Linux PKGBUILD
# Maintainer: Samo Turk <samo.turk@gmail.com>
pkgname=rdkit
_pkgname=RDKit
pkgver=2014_09_1
pkgrel=1
pkgdesc="RDKit - A collection of cheminformatics and machine-learning software written in C++ and Python."
arch=("i686" "x86_64")
url="http://rdkit.org/"
license=('New BSD License')
depends=( 'bison' 'boost' 'boost-libs' 'cmake' 'flex' 'python2' 'python2-numpy' 'sqlite3' )
@samoturk
samoturk / Dockerfile-rdkit
Last active August 23, 2022 01:29
Docker file that installs docker container with rdkit, ipython notebook and matplotlib
# Docker file that installs docker container with rdkit, ipython notebook and matplotlib
#
# rename this file to "Dockerfile"
# build with: "sudo docker build -t rdkit ."
# run with: "sudo docker run -p 127.0.0.1:8889:8888 rdkit "
# NOTE that here port 8888 gets mapped to 8889.
# point your browser to http://127.0.0.1:8889/
FROM saltstack/ubuntu-13.10
# Add universe repository
import math
import pybel
def squared_distance(coordsA, coordsB):
"""Find the squared distance between two 3-tuples"""
sqrdist = sum( (a-b)**2 for a, b in zip(coordsA, coordsB) )
return sqrdist
def rmsd(allcoordsA, allcoordsB):
"""Find the RMSD between two lists of 3-tuples"""