Skip to content
/ gpt Public
forked from lehner/gpt

A python measurement interface for Grid

License

Notifications You must be signed in to change notification settings

ssolbUR/gpt

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GPT Logo

GPT - Grid Python Toolkit

GPT is a Python3 measurement interface for Grid.

Installation

GPT is developed with the feature/gpt branch of https://github.com/lehner/Grid.

Setting up the runtime

source gpt/scripts/source.sh

Usage

import gpt as g

# load gauge field and describe fermion
gauge=g.qcd.gaugefield("params.txt")
light=g.qcd.fermion("light.txt")

# create point source
src=g.mspincolor(gauge.dp.grid)
g.create.point(src, [0,0,0,0])

# solve
prop=light.solve.exact(src)

# pion
corr_pion=g.slice(g.trace(g.adj(prop)*prop),3)
print("Pion two point:")
print(corr_pion)

# vector
gamma=g.gamma
corr_vector=g.slice(g.trace(gamma[0]*g.adj(prop)*gamma[0]*prop),3)
print("Vector two point:")
print(corr_vector)

About

A python measurement interface for Grid

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 52.9%
  • Python 44.6%
  • C 1.3%
  • Shell 1.2%