Skip to content

CyrilWaechter/python-materialsdb

Repository files navigation

python-materialsdb is an unofficial python library for materialsdb.org an open format and database for building materials.

Features :

Package

  • serialiser.py :
    • from xml : deserialise from materialsdb*.xsd compliant xml file
    • to xml : serealise classes to a materialsdb*.xsd compliant xml file
  • classes.py : generated classes corresponding to XML elements
  • cache.py : cache latest materials data from producers
  • config.py : set and get user config as language and country
  • ifc/project_library.py : convert deserialised source into IFC (IfcProjectLibrary)

devutils

  • classes_generator.py : generate classes (dataclasses except for simple type) for materialsdb*.xsd elements

config

Materials data are often localized. You can set your language and country this way:

from materialsdb import config

config.set_lang("fr")
config.set_country("CH")

Note: in materialsdb standard languages are ISO 639-1 codes and countries are ISO_3166-1_alpha-2 codes.

Usage examples :

Check out some examples:

How to install

Using pip

pip install python-materialsdb

Dependencies

Third parties :

About

an unofficial python library for http://www.materialsdb.org an open standard for materials data

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages