|
[PyFeyn] pyfeyn in ubuntu 13.10George S. Williams physicist at websterling.comWed Mar 26 03:40:31 GMT 2014
Hello, Alejandro, There is a bug in pyfeyn-0.3.4. In the file deco.py, change line 16 from 1, selfsize, 45, self.constriction, to 1, selfsize, 45, 1, I think that this will solve your problem. Let me know if this works and have fun making Feynman Diagrams. George S. Williams On 3/25/2014 11:07 PM, Alejandro Gomez Espinosa wrote: > Hi > > I was trying to use your package and I found an error. First I > installed your package like: > sudo python setup.py install > seems like is working because I opened python and I could import that > package. But when I copied the first of your examples, in a file > inside the untar folder, I got this error: > > Traceback (most recent call last): > File "./test.py", line 17, in <module> > fd.draw("pyfeyn-test4.pdf") > File "/home/algomez/Downloads/pyfeyn-0.3.4/pyfeyn/diagrams.py", line > 69, in draw > c = self.drawToCanvas() > File "/home/algomez/Downloads/pyfeyn-0.3.4/pyfeyn/diagrams.py", line > 61, in drawToCanvas > obj.draw(self.currentCanvas) > File "/home/algomez/Downloads/pyfeyn-0.3.4/pyfeyn/lines.py", line > 329, in draw > canvas.stroke(path, styles) > File "/usr/lib/python2.7/dist-packages/pyx/canvas.py", line 298, in > stroke > self.draw(path, [deco.stroked]+list(attrs)) > File "/usr/lib/python2.7/dist-packages/pyx/canvas.py", line 284, in draw > adeco.decorate(dp, self.texrunner) > File "/home/algomez/Downloads/pyfeyn-0.3.4/pyfeyn/deco.py", line 46, > in decorate > 1, self.size, 45, constrictionlen) > File "/home/algomez/Downloads/pyfeyn-0.3.4/pyfeyn/deco.py", line 16, > in getarrowpath > 1, selfsize, 45, self.constriction, > NameError: global name 'self' is not defined > > any ideas? I will love to create Feynman Diagrams in python!! :D > > cheers, > > */Alejandro Gomez Espinosa /* > /Department of Physics and Astronomy / > /Rutgers, The State University of New Jersey / > /136 Frelinghuysen Road / > /Piscataway, NJ 08854-8019 USA/ > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://www.hepforge.org/lists-archive/pyfeyn/attachments/20140325/df4f89d1/attachment.html>
More information about the PyFeyn mailing list |