Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(6)  |  Call(3)  |  Derive(0)  |  Import(3)

src/m/a/matter-0.8-r960-20110308/examples/storeStructureObject.py   matter(Download)
from matter.orm.Atom import Atom
from matter.orm.Lattice import Lattice
from matter.orm.Structure import Structure
 
at1 = Atom('C', [0.333333333333333, 0.666666666666667, 0])
hexag.id = 'hexag'
 
graphite = Structure( [ at1, at2], lattice = hexag)
graphite.id = 'graphite'
orm.save(graphite)

src/m/a/matter-0.8-r960-20110308/examples/antiquated/storeStructure.py   matter(Download)
from matter.orm.Atom import Atom
from matter.orm.Lattice import Lattice
from matter.orm.Structure import Structure
 
 
db.commit()
 
graphite = Structure( [ at1, at2], lattice = hexag)
graphite.id = 'graphite'
db.insertRow(graphite)

src/m/a/matter-0.8-r960-20110308/tests/TestStructureOrm.py   matter(Download)
sys.path.insert(0,os.path.abspath('..'))
 
from matter.orm.Structure import Structure
from matter.orm.Atom import Atom
from matter.orm.Lattice import  Lattice
        lattice = Lattice(a=1, b=2, c=3, alpha=89, beta=91, gamma=92)
 
        struct = Structure(atoms=atoms, lattice=lattice)
 
        orm = self.orm