Emil Andreasen Klahn
eandklahn / phd_repo Goto Github PK
View Code? Open in Web Editor NEWA collection of Python-code that I use/have been using for my work in neutron diffraction, molecular magnetism and as a TA in physical chemistry
A collection of Python-code that I use/have been using for my work in neutron diffraction, molecular magnetism and as a TA in physical chemistry
Emil Andreasen Klahn
there are multiple classes called crystalStructure under crystallography.py, crystallography_v1.0.py and cifoperations/crystalStructure.py
these should be combined
Make it so that the "F XXm 3 ..." card is constructed automatically when the magnetic atom is a lanthanide
crystalStructure-class does not save the Uiso-value from the cif-file when the Utype is Uani
It is a problem because generating a cry-file when occupancies are not 1 requires the Uiso-value to be put into the A-card
I think this will make it more intuitive and will also make it easier to allow for creating an empty class
Example of problem
from cifoperations import cc
dbm = cc.crystalStructure('C:\Users\Emil\Documents\Uddannelse\PhD\pnd_susceptibility\magnetic_ellipsoids\DBM.cif')
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Emil\Documents\Uddannelse\PhD\pyLIB\cifoperations\cc.py", line 120, in init
self._read_CIF()
File "C:\Users\Emil\Documents\Uddannelse\PhD\pyLIB\cifoperations\cc.py", line 180, in _read_CIF
cf = CifFile.ReadCif(self.cifFile)
File "C:\Program Files (x86)\Python36-32\lib\site-packages\CifFile\CifFile_module.py", line 3108, in ReadCif
permissive=permissive)
File "C:\Program Files (x86)\Python36-32\lib\site-packages\CifFile\StarFile.py", line 2174, in ReadStar
filestream = urlopen(my_uri)
File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 223, in urlopen
return opener.open(url, data, timeout)
File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 526, in open
response = self._open(req, data)
File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 549, in _open
'unknown_open', req)
File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 504, in _call_chain
result = func(*args)
File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 1388, in unknown_open
raise URLError('unknown url type: %s' % type)
urllib.error.URLError:
import os
os.getcwd()
'C:\Users\Emil'
it looks like the function _read_symmop in cifoperations.symmetry is reading the symmetry element wrong when the translation is given before the rotation,
i.e.
x-1/2, -y-1/2, z-1/2 is being read correctly
but for
1/2+X,1/2-Y,1/2+Z,
the translational part is being returned as (0,0,0).
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.