Coder Social home page Coder Social logo

ddt's Introduction

ddt

A toolkit for drug discovery research

Usage:

Terminal

 $ python -m ddt.utility --help
usage: utility.py [-h]
                  (--smiles SMILES | --sdf SDF | --smiles_file SMILES_FILE)
                  [--title] [--smiles_column SMILES_COLUMN]
                  [--name_column NAME_COLUMN] [--delimiter DELIMITER]
                  (--npy NPY | --csv CSV)

Feature generation from SMILES and SDF

optional arguments:
  -h, --help            show this help message and exit
  --smiles SMILES       SMILES string as "SMILES"
  --sdf SDF             SDF file location
  --smiles_file SMILES_FILE
                        SMILES file
  --npy NPY             Numpy file for writing the features
  --csv CSV             CSV file to write the features

Argument for SMILES file parsing:
  --title               If the file contains a header
  --smiles_column SMILES_COLUMN
                        Column index for SMILES entries
  --name_column NAME_COLUMN
                        Column index for SMILES names
  --delimiter DELIMITER
                        Delimiter, e.g., ' ' or ','

Example: python -m ddt.utility --smiles_file oo.csv --title --smiles_column 3 --name_column 1 --delimiter , --npy test

Script

Python 3.6.10 |Anaconda, Inc.| (default, Jan  7 2020, 21:14:29)
[GCC 7.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from ddt.utility import FeatureGenerator
>>> ft = FeatureGenerator()
>>> ft.load_smiles("CCCC")
>>> c, f = ft.extract_tpatf()

TopologicalPharmacophoreAtomTripletsFingerprints.pl: Starting...

Processing options...
Checking input SD file(s)...

Processing file /tmp/tmpwvy0hglv/temp.sdf...
Generating text file /tmp/tmp2mc2qv61/temp.csv...

Number of compounds: 1
Number of compounds processed successfully during fingerprints generation: 1
Number of compounds ignored during fingerprints generation: 0

TopologicalPharmacophoreAtomTripletsFingerprints.pl:Done...

Total time:  0 wallclock secs ( 0.05 usr +  0.00 sys =  0.05 CPU)

>>> print(c)
['Cmpd1']
>>> f.shape
(1, 2692)

ddt's People

Contributors

hassanmohsin avatar

Stargazers

Tailong Lei avatar Xiaowen Hu avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.