Skip to content

Instantly share code, notes, and snippets.

View ghutchis's full-sized avatar

Geoff Hutchison ghutchis

View GitHub Profile
@ghutchis
ghutchis / CMakeLists.txt
Created March 15, 2018 01:33
Reset View template for avogadrolibs
include_directories(${CMAKE_CURRENT_BINARY_DIR})
avogadro_plugin(ResetView
"Manipulate the view camera."
ExtensionPlugin
resetview.h
ResetView
"resetview.cpp"
""
)
@ghutchis
ghutchis / gen-conformers.py
Created March 6, 2018 19:33
Generate conformers with normal mode sampling
#!/usr/bin/env python
from __future__ import print_function
import sys
import logging
import numpy as np
from cclib.io import ccopen
from nms import nmsgenerator
from masses import element_masses
@ghutchis
ghutchis / gsoc2018.md
Created February 12, 2018 19:11
Google Summer of Code 2018

Are you a student? Know a student?

Want to get paid to write open source chemistry code this summer?

Following up on a successful 2016 and 2017, the Open Chemistry "umbrella" group of open source chemistry projects is looking for student proposals for Google Summer of Code (https://summerofcode.withgoogle.com/how-it-works/)

Applications and proposals are due from March 12th until March 27th. Students who are selected are paid between $US 2400 and $US 6600 for completing their work (https://developers.google.com/open-source/gsoc/help/student-stipends#amounts).

Students can submit their own ideas or work on suggested projects (Avogadro, cclib, RDKit, 3Dmol.js, MSDK, NWChem, Open Babel, DeepChem, etc.) Ideas range from easy-to-use web repositories for computational chemistry, OpenMM and GPU enabled molecular mechanics, volumetric rendering, to advanced analytical methods for quantum chemistry. http://wiki.openchemistry.org/GSoC_Ideas_2018

@ghutchis
ghutchis / gwiddion-batch.py
Created June 30, 2017 23:17
Batch script through Igor AFM data
import glob, sys
try:
import gwy
except:
print "You need to install Gwyddion first"
sys.exit(0)
# Script adapted from the Gwyddion documentation
# http://gwyddion.net/documentation/user-guide-en/pygwy.html
@ghutchis
ghutchis / readingList.py
Created May 11, 2017 02:00
Parse Safari Reading List using Python
import os
import plistlib
import requests
INPUT_FILE = os.path.join(os.environ['HOME'], 'Library/Safari/Bookmarks.plist')
OUTPUT_FILE = 'readinglist.txt'
# Load and parse the Bookmarks file
with open(INPUT_FILE, 'rb') as plist_file:
plist = plistlib.load(plist_file)
@ghutchis
ghutchis / piezo-dist.py
Created March 22, 2017 23:39
piezo-distance
#!/usr/bin/env python
import sys
import openbabel as ob
import pybel
for filename in sys.argv[1:]:
mol = pybel.readfile("g09", filename).next()
nitro = mol.atoms[0]
amine = mol.atoms[0]
@ghutchis
ghutchis / gsoc2017.md
Last active March 16, 2017 21:11
OpenChemistry in Google Summer of Code 2017

Are you a student? Know a student?

Want to get paid to write open source chemistry code this summer?

Following up on a successful 2016, the Open Chemistry "umbrella" group of open source chemistry projects is looking for student proposals for Google Summer of Code (https://summerofcode.withgoogle.com/how-it-works/)

Applications and proposals are due from March 20th until April 3rd. Students who are selected are paid between $US 2400 and $US 6600 for completing their work (https://developers.google.com/open-source/gsoc/help/student-stipends#amounts).

Students can submit their own ideas or work on suggested projects (Avogadro, cclib, RDKit, 3Dmol.js, MSDK, NWChem, Open Babel) Ideas range from easy-to-use web repositories for computational chemistry, OpenMM and GPU enabled molecular mechanics, volumetric rendering, to advanced analytical methods for quantum chemistry. http://wiki.openchemistry.org/GSoC_Ideas_2017

#!/usr/bin/env python
import sys
from cclib.io import ccopen
import logging
for filename in sys.argv[1:]:
file = ccopen(filename)
# Strip off common extensions
@ghutchis
ghutchis / molcsv.py
Created May 14, 2015 18:35
Print molecule "report" as a CSV file
#!/usr/bin/env python
import sys, os
import pybel
# don't need to reimport openbabel
ob = pybel.ob
for argument in sys.argv[1:]:
filename, extension = os.path.splitext(argument)
@ghutchis
ghutchis / GZCGUPFRVQAUEE-SLPGGIOYSA-N.mol2
Created April 1, 2015 15:25
3DMol Issue (SDF vs. Mol2)
@<TRIPOS>MOLECULE
d-(+)-glucose
24 23 0 0 0
SMALL
USER_CHARGES
@<TRIPOS>ATOM
1 O -3.9862 -0.0915 -0.4753 O.2 1 UNL11111 -0.4322
2 C -3.1086 -0.7606 0.0104 C.2 1 UNL11111 0.3255
3 C -1.9542 -0.0724 0.7328 C.3 1 UNL11111 -0.0217