A package for accessing chemical elements data.
eben60 / mendeleev.jl Goto Github PK
View Code? Open in Web Editor NEWA Julia package for accessing chemical elements data.
Home Page: https://eben60.github.io/Mendeleev.jl/
License: Other
A Julia package for accessing chemical elements data.
Home Page: https://eben60.github.io/Mendeleev.jl/
License: Other
A package for accessing chemical elements data.
if you're using sequential integers as keys, you might as well use a Vector with sequential integer indices, as that has faster
https://github.com/Eben60/Mendeleev.jl/blob/main/src/data.jl/ionization_data.jl
This issue is used to trigger TagBot; feel free to unsubscribe.
If you haven't already, you should update your TagBot.yml
to include issue comment triggers.
Please see this post on Discourse for instructions and more details.
If you'd like for me to do this for you, comment TagBot fix
on this issue.
I'll open a PR within a few hours, please be patient!
Currently install/compile of the package takes some 3 min. on my notebook. Most of the time is spent in the initialisation of the Element_M
structs in the line
elements_arr = Vector{Element_M}(Element_M.(els_data)) # no idea why not working without this type casting
of the file Mendeleev.jl/src/Mendeleev.jl
I suppose the long compilation time is due to the type instability because of the missing
s - almost every 70-elements-tuple has a different type. One could use NaNs, empty strings etc. instead. Or probably the loop parallelization could reduce the compile time to something more acceptable like 1 min.
This package is thought as an addition or replacement for PeriodicTable.jl using the data from mendeleev python package.
Though work-in-progress yet, in it's current state it can already be used as a plug-in replacement for PeriodicTable.jl. The package installable code is based mostly on the PeriodicTable.jl code, but the Element_M struct code and the data (the files Element_M_def.jl and elements_data.jl resp.) are generated by a separate module from the SQLite database which was shamelessly taken from mendeleev -- @lmmentel, thank you for your work!
The Number, Symbol & Name indexing of ELEMENTS_M are the same as in PeriodicTable, the elements representation the same, too. All fields of PeriodicTable Element
are supported, in addition to some 60+ fields from mendeleev - see mendeleev documentation . mendeleev database is actively maintained, and the data seem to be taken over from reliable sources. Updating Mendeleev.jl from the database is a matter of running a script.
The compiled code is static like in PeriodicTable, and using Mendeleev
takes just 0.5 s on my modest i5 Notebook (0.13 s with PeriodicTable pre-loaded, thus further improvement possible), and takes 15 s for pre-compile during the installation.
I have started the package just for fun and as an excersise in Julia. Now - what can we do with it?
In the last case I may announce it, but I am not sure about registering the package.
Now I would humbly ask the PeriodicTable.jl author and contributors for their opinion. @rahulkp220, @carstenbauer, @Gregstrq, @stevengj - what do you think?
@Gregstrq - you data collection on isotopes could be put into a package in a similar way. And if somebody (@lmmentel ? ๐ ) imports your collection into a database, a corresponding Julia package can be created based on the code of this package at a minimal cost.
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.