GithubHelp home page GithubHelp logo

dkratzert / dsr Goto Github PK

View Code? Open in Web Editor NEW
5.0 2.0 1.0 486.9 MB

Refinement of disordered structures with SHELXL

Home Page: https://dkratzert.de/dsr.html

Python 99.35% Shell 0.01% TeX 0.40% Inno Setup 0.23% Batchfile 0.01%
dsr python molecule fragments database shelxl crystallography

dsr's Introduction

Packaging status

Lates Release Unit tests Contributions PyPI package

DSR

The program DSR consists of a text database with fragments of molecules and the DSR program. It acts as a preprocessor for SHELXL .res files. The user inserts a special command in the SHELXL .res file and the DSR program reads this information to put a molecule or fragment with the desired atoms on the position of the target atoms or q-peaks in the unit cell. Bond restraints can be either applied from the database to the molecule or automatically generated.

I apologize for the messy code. This was my first bigger project...

You have either a command line version:

C:\Users\daniel>dsr
----------------------------------------------------- D S R - v238 -------------------------------------
Disordered Structure Refinement (DSR)

Example DSR .res file command line:
REM DSR PUT/REPLACE "Fragment" WITH C1 C2 C3 ON Q1 Q2 Q3 PART 1 OCC -21 =
  RESI DFIX
---------------------------------------------------------------------------------------------------------
   PUT:     Just put the fragment source atoms here.
   REPLACE: Replace atoms of PART 0 in 1.3 A distance around target atoms.
---------------------------------------------------------------------------------------------------------

optional arguments:
  -h, --help            show this help message and exit
  -r "res file" ["res file" ...]
                        res file with DSR command
  -re "res file" ["res file" ...]
                        res file with DSR command (write restraints to external file)
  -e "fragment"         export fragment as .res/.png file
  -c "fragment"         export fragment to clipboard
  -t                    inverts the current fragment
  -i "tgz file"         import a fragment from GRADE (needs .tgz file)
  -l                    list names of all database entries
  -s "string"           search the database for a name
  -g                    keep group rigid (no restraints)
  -u                    Update DSR to the most current version
  -n                    do not refine after fragment transfer

Or a graphical user interface in ShelXle:

DSR main window

DSR editor

dsr's People

Contributors

dkratzert avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

trellixvulnteam

dsr's Issues

Choose esd for restraints prior to fragment fit

  • let user choose the esd prior to the fragment fit
  • Should I apply this to one fragment explicitly? e.g. SADI 0.001 C1_2 C2_2 ...
    • Or alternatively as option to apply to all or a single fragment

Import of GRADE2 fails

DSR version: 237
Python version: 3.11.0 (main, Oct 24 2022, 18:26:48) [MSC v.1933 64 bit (AMD64)]
Commandline: Namespace(res_file='', external_restr=False, export_fragment='', export_clip='', invert=False, import_grade='.\QPD.gradeserver_all.tgz', list_db=False, search_string='', rigid_group=False, selfupdate=False, export_all=False, list_db_csv=False, search_extern=False, head_for_gui='', shelxl_ex=False, no_refine=False, target=[])
Platform: Windows 10, Windows LAPTOP-PJSBHG2Q 10 10.0.22621 AMD64 Intel64 Family 6 Model 142 Stepping 12, GenuineIntel
2023-06-13 15:44:48
Traceback (most recent call last):
File "C:\Program Files (x86)\DSR\dsr.py", line 485, in
main()
File "C:\Program Files (x86)\DSR\dsr.py", line 463, in main
dsr = DSR(options)
^^^^^^^^^^^^
File "C:\Program Files (x86)\DSR\dsr.py", line 150, in init
mog.write_user_database()
File "C:\Program Files (x86)\DSR\dbfile.py", line 1123, in write_user_database
imported_entry = self.bild_grade_db_entry()
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files (x86)\DSR\dbfile.py", line 1102, in bild_grade_db_entry
'comments' : self.get_comments(),
^^^^^^^^^^^^^^^^^^^
File "C:\Program Files (x86)\DSR\dbfile.py", line 1016, in get_comments
name = 'REM Name: ' + self.get_name_from_pdbfile()
~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
TypeError: can only concatenate str (not "NoneType") to str

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.