[sage-combinat-devel] Sage Days 64

2014-09-09 Thread Anne Schilling
Dear All!

Dan Bump, Travis Scrimshaw and I are going to organize Sage Days 64 (=2^6 !!)
at UC Davis March 17-20, 2015. A preliminary website can be found here

http://wiki.sagemath.org/days64

If you are interested in participating, please sign up on the wiki or
drop us a line!

Hope to see you there,

Anne, Dan, Travis

-- 
You received this message because you are subscribed to the Google Groups 
sage-combinat-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-combinat-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-combinat-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-combinat-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-combinat-devel] Sage Days 64

2014-09-09 Thread Paul-Olivier Dehaye
Dear Anne,

 2^6
4

Sincerely,
Paul


Paul-Olivier Dehaye
SNF Assistant Professor of Mathematics
University of Zurich
http://user.math.uzh.ch/dehaye/contact_info.txt

On Wed, Sep 10, 2014 at 2:42 AM, Anne Schilling a...@math.ucdavis.edu
wrote:

 Dear All!

 Dan Bump, Travis Scrimshaw and I are going to organize Sage Days 64 (=2^6
 !!)
 at UC Davis March 17-20, 2015. A preliminary website can be found here

 http://wiki.sagemath.org/days64

 If you are interested in participating, please sign up on the wiki or
 drop us a line!

 Hope to see you there,

 Anne, Dan, Travis

 --
 You received this message because you are subscribed to the Google Groups
 sage-combinat-devel group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to sage-combinat-devel+unsubscr...@googlegroups.com.
 To post to this group, send email to sage-combinat-devel@googlegroups.com.
 Visit this group at http://groups.google.com/group/sage-combinat-devel.
 For more options, visit https://groups.google.com/d/optout.


-- 
You received this message because you are subscribed to the Google Groups 
sage-combinat-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-combinat-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-combinat-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-combinat-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] pyopenssl

2014-09-09 Thread Jan Groenewald
Hi

I'm running Ubuntu 14.04 and the PPA which is the downloaded binary.

I wanted to enable notebook(secure=True), which prompted me to install
pyopenssl.

sage -i pyopenssl successfully installed but prompted me to make.
make finished without error.

sage now does not start:

0 jan@muizenberg:/var/autofs/misc/home/jan$sage
┌┐
│ Sage Version 6.3, Release Date: 2014-08-10 │
│ Type notebook() for the browser-based notebook interface.│
│ Type help() for help.│
└┘

**

Oops, Sage crashed. We do our best to make it stable, but...

A crash report was automatically generated with the following information:
  - A verbatim copy of the crash traceback.
  - A copy of your input history during this session.
  - Data on your current Sage configuration.

It was left in the file named:
'/var/autofs/misc/home/jan/.sage/ipython-2.1.0/Sage_crash_report.txt'
If you can email this file to the developers, the information in it will
help
them in understanding and correcting the problem.

You can mail it to: sage-support at sage-supp...@googlegroups.com
with the subject 'Sage Crash Report'.

If you want to do it now, the following command will work (under Unix):
mail -s 'Sage Crash Report' sage-supp...@googlegroups.com 
/var/autofs/misc/home/jan/.sage/ipython-2.1.0/Sage_crash_report.txt

To ensure accurate tracking of this issue, please file a report about it at:
http://trac.sagemath.org

Hit Enter to quit (your terminal may close):
1 jan@muizenberg:/var/autofs/misc/home/jan$ls
/usr/lib/sagemath/local/lib/libcsage.so
/usr/lib/sagemath/local/lib/libcsage.so


Attached the error file which says cannot find libcsage.so.

Any ideas?

Regards,
Jan

-- 
  .~.
  /V\ Jan Groenewald
 /( )\www.aims.ac.za
 ^^-^^

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.
***

IPython post-mortem report

{'commit_hash': '00199fb',
 'commit_source': 'installation',
 'default_encoding': 'UTF-8',
 'ipython_path': '/usr/lib/sagemath/local/lib/python2.7/site-packages/IPython',
 'ipython_version': '2.1.0',
 'os_name': 'posix',
 'platform': 'Linux-3.13.0-35-generic-x86_64-with-debian-jessie-sid',
 'sys_executable': '/usr/lib/sagemath/local/bin/python',
 'sys_platform': 'linux2',
 'sys_version': '2.7.8 (default, Aug 10 2014, 21:20:38) \n[GCC 4.8.2]'}

***



***

Crash traceback:

---
ImportErrorPython 2.7.8: /usr/lib/sagemath/local/bin/python
   Tue Sep  9 08:59:20 2014
A problem occured executing Python code.  Here is the sequence of function
calls leading up to the error, with the most recent (innermost) call last.
/usr/lib/sagemath/src/bin/sage-ipython in module()
  1 #!/usr/bin/env python
  2 # -*- coding: utf-8 -*-
  3 
  4 Sage IPython startup script.
  5 
  6 from sage.repl.interpreter import SageTerminalApp
  7 
  8 # installs the extra readline commands before the IPython 
initialization begins.
  9 from sage.repl.readline_extra_commands import *
 10 
 11 app = SageTerminalApp.instance()
--- 12 app.initialize()
global app.initialize = bound method SageTerminalApp.initialize of 
sage.repl.interpreter.SageTerminalApp object at 0x7fa8a6a75310
 13 app.start()

/usr/lib/sagemath/local/lib/python2.7/site-packages/IPython/terminal/ipapp.py 
in initialize(self=sage.repl.interpreter.SageTerminalApp object, argv=None)

/usr/lib/sagemath/local/lib/python2.7/site-packages/IPython/config/application.py
 in catch_config_error(method=function initialize, 
app=sage.repl.interpreter.SageTerminalApp object, *args=(None,), **kwargs={})
 77 
 78 
#-
 79 # Application class
 80 
#-
 81 
 82 @decorator
 83 def catch_config_error(method, app, *args, **kwargs):
 84 Method decorator for catching invalid config 
(Trait/ArgumentErrors) during init.
 85 
 86 On a TraitError (generally caused by bad config), this will print 
the trait's
 

Re: [sage-devel] error installing package ppl-1.1

2014-09-09 Thread Francois Bissey
No obvious things in this log. But a careful reading shows that both
glpk.h and glpk/glpk.h where found. glpk in sage only ships glpk.h
so the other one must come from the system.
The output of rpm -ql glpk-dev or would it be glpk-devel would
show us what has been detected from the system.

But like I said earlier in answering David, fixing it not as obvious
as it seems.

François

On 9/09/2014, at 20:51, 'Paul Mercat' via sage-devel 
sage-devel@googlegroups.com wrote:

 Here is the file 
 /home/paul.mercat/sage/local/var/tmp/sage/build/ppl-1.1/src/config.log 
 
 Paul
 
 Le mardi 9 septembre 2014 07:02:11 UTC+2, François a écrit :
 
 On 9/09/2014, at 16:32, Dr. David Kirkby (Kirkby Microwave Ltd) 
 drki...@kirkbymicrowave.co.uk wrote: 
 
  
  On 9 Sep 2014 00:25, François Bissey francoi...@canterbury.ac.nz wrote: 
   But it is almost certain the system glpk 
   is the problem. 
  
  If so, given Sage ships glpk, and quite a number of other packages to 
  ensure that we control exactly the versions being linked, then I suspect 
  the  ppl package needs modifying to ensure it links against the version of 
  glpk shipped in Sage and not some other version which may be on the system. 
  
  Although I have not looked at the code; that should be a fairly easy fix. 
  
 I have looked at the code and unfortunately there is nothing to give a 
 location 
 for glpk in ppl's configure script. We have to make sure CPPFLAGS and LDFLAGS 
 point to the good spot. 
 
 Francois 
 
 
 This email may be confidential and subject to legal privilege, it may 
 not reflect the views of the University of Canterbury, and it is not 
 guaranteed to be virus free. If you are not an intended recipient, 
 please notify the sender immediately and erase all copies of the message 
 and any attachments. 
 
 Please refer to http://www.canterbury.ac.nz/emaildisclaimer for more 
 information. 
 
 -- 
 You received this message because you are subscribed to the Google Groups 
 sage-devel group.
 To unsubscribe from this group and stop receiving emails from it, send an 
 email to sage-devel+unsubscr...@googlegroups.com.
 To post to this group, send email to sage-devel@googlegroups.com.
 Visit this group at http://groups.google.com/group/sage-devel.
 For more options, visit https://groups.google.com/d/optout.
 config.log


This email may be confidential and subject to legal privilege, it may
not reflect the views of the University of Canterbury, and it is not
guaranteed to be virus free. If you are not an intended recipient,
please notify the sender immediately and erase all copies of the message
and any attachments.

Please refer to http://www.canterbury.ac.nz/emaildisclaimer for more
information.

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] error installing package ppl-1.1

2014-09-09 Thread 'Paul Mercat' via sage-devel
[paul.mercat@octopus ~]$ rpm -ql glpk-dev
package glpk-dev is not installed

Le mardi 9 septembre 2014 11:03:50 UTC+2, François a écrit :

 No obvious things in this log. But a careful reading shows that both 
 glpk.h and glpk/glpk.h where found. glpk in sage only ships glpk.h 
 so the other one must come from the system. 
 The output of “rpm -ql glpk-dev” or would it be glpk-devel would 
 show us what has been detected from the system. 

 But like I said earlier in answering David, fixing it not as obvious 
 as it seems. 

 François 

 On 9/09/2014, at 20:51, 'Paul Mercat' via sage-devel 
 sage-...@googlegroups.com javascript: wrote: 

  Here is the file 
 /home/paul.mercat/sage/local/var/tmp/sage/build/ppl-1.1/src/config.log 
  
  Paul 
  
  Le mardi 9 septembre 2014 07:02:11 UTC+2, François a écrit : 
  
  On 9/09/2014, at 16:32, Dr. David Kirkby (Kirkby Microwave Ltd) 
 drki...@kirkbymicrowave.co.uk wrote: 
  
   
   On 9 Sep 2014 00:25, François Bissey francoi...@canterbury.ac.nz 
 wrote: 
But it is almost certain the system glpk 
is the problem. 
   
   If so, given Sage ships glpk, and quite a number of other packages to 
 ensure that we control exactly the versions being linked, then I suspect 
 the  ppl package needs modifying to ensure it links against the version of 
 glpk shipped in Sage and not some other version which may be on the system. 
   
   Although I have not looked at the code; that should be a fairly easy 
 fix. 
   
  I have looked at the code and unfortunately there is nothing to give a 
 location 
  for glpk in ppl’s configure script. We have to make sure CPPFLAGS and 
 LDFLAGS 
  point to the good spot. 
  
  Francois 
  
  
  This email may be confidential and subject to legal privilege, it may 
  not reflect the views of the University of Canterbury, and it is not 
  guaranteed to be virus free. If you are not an intended recipient, 
  please notify the sender immediately and erase all copies of the message 
  and any attachments. 
  
  Please refer to http://www.canterbury.ac.nz/emaildisclaimer for more 
  information. 
  
  -- 
  You received this message because you are subscribed to the Google 
 Groups sage-devel group. 
  To unsubscribe from this group and stop receiving emails from it, send 
 an email to sage-devel+...@googlegroups.com javascript:. 
  To post to this group, send email to sage-...@googlegroups.com 
 javascript:. 
  Visit this group at http://groups.google.com/group/sage-devel. 
  For more options, visit https://groups.google.com/d/optout. 
  config.log 


 This email may be confidential and subject to legal privilege, it may 
 not reflect the views of the University of Canterbury, and it is not 
 guaranteed to be virus free. If you are not an intended recipient, 
 please notify the sender immediately and erase all copies of the message 
 and any attachments. 

 Please refer to http://www.canterbury.ac.nz/emaildisclaimer for more 
 information. 


-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: pyopenssl

2014-09-09 Thread Volker Braun
If you used the PPA shouldn't sage -i have failed with a permission 
error, how come you can write into the Sage install? In any case, IMHO you 
are best off compiling all of Sage if you want to install (compile) 
optional packages as well.



On Tuesday, September 9, 2014 8:02:08 AM UTC+1, Jan Groenewald wrote:

 Hi

 I'm running Ubuntu 14.04 and the PPA which is the downloaded binary.

 I wanted to enable notebook(secure=True), which prompted me to install 
 pyopenssl.

 sage -i pyopenssl successfully installed but prompted me to make.
 make finished without error.

 sage now does not start:

 0 jan@muizenberg:/var/autofs/misc/home/jan$sage
 ┌┐
 │ Sage Version 6.3, Release Date: 2014-08-10 │
 │ Type notebook() for the browser-based notebook interface.│
 │ Type help() for help.│
 └┘

 **

 Oops, Sage crashed. We do our best to make it stable, but...

 A crash report was automatically generated with the following information:
   - A verbatim copy of the crash traceback.
   - A copy of your input history during this session.
   - Data on your current Sage configuration.

 It was left in the file named:
 '/var/autofs/misc/home/jan/.sage/ipython-2.1.0/Sage_crash_report.txt'
 If you can email this file to the developers, the information in it will 
 help
 them in understanding and correcting the problem.

 You can mail it to: sage-support at sage-s...@googlegroups.com 
 javascript:
 with the subject 'Sage Crash Report'.

 If you want to do it now, the following command will work (under Unix):
 mail -s 'Sage Crash Report' sage-s...@googlegroups.com javascript:  
 /var/autofs/misc/home/jan/.sage/ipython-2.1.0/Sage_crash_report.txt

 To ensure accurate tracking of this issue, please file a report about it 
 at:
 http://trac.sagemath.org

 Hit Enter to quit (your terminal may close):
 1 jan@muizenberg:/var/autofs/misc/home/jan$ls 
 /usr/lib/sagemath/local/lib/libcsage.so 
 /usr/lib/sagemath/local/lib/libcsage.so


 Attached the error file which says cannot find libcsage.so.

 Any ideas?

 Regards,
 Jan

 -- 
   .~. 
   /V\ Jan Groenewald
  /( )\www.aims.ac.za
  ^^-^^ 
  

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Re: pyopenssl

2014-09-09 Thread Jan Groenewald
Hi

I can change the permissions on the PPA folder, these are imaged desktops
for labs, and I can always test and reimage on any computer.
I have in the past often installed optional packages with the PPA.

I will try from source, and see if it persists.

Regards,
Jan


On 9 September 2014 11:39, Volker Braun vbraun.n...@gmail.com wrote:

 If you used the PPA shouldn't sage -i have failed with a permission
 error, how come you can write into the Sage install? In any case, IMHO you
 are best off compiling all of Sage if you want to install (compile)
 optional packages as well.



 On Tuesday, September 9, 2014 8:02:08 AM UTC+1, Jan Groenewald wrote:

 Hi

 I'm running Ubuntu 14.04 and the PPA which is the downloaded binary.

 I wanted to enable notebook(secure=True), which prompted me to install
 pyopenssl.

 sage -i pyopenssl successfully installed but prompted me to make.
 make finished without error.

 sage now does not start:

 0 jan@muizenberg:/var/autofs/misc/home/jan$sage
 ┌┐
 │ Sage Version 6.3, Release Date: 2014-08-10 │
 │ Type notebook() for the browser-based notebook interface.│
 │ Type help() for help.│
 └┘

 **

 Oops, Sage crashed. We do our best to make it stable, but...

 A crash report was automatically generated with the following information:
   - A verbatim copy of the crash traceback.
   - A copy of your input history during this session.
   - Data on your current Sage configuration.

 It was left in the file named:
 '/var/autofs/misc/home/jan/.sage/ipython-2.1.0/Sage_crash_report.txt'
 If you can email this file to the developers, the information in it will
 help
 them in understanding and correcting the problem.

 You can mail it to: sage-support at sage-s...@googlegroups.com
 with the subject 'Sage Crash Report'.

 If you want to do it now, the following command will work (under Unix):
 mail -s 'Sage Crash Report' sage-s...@googlegroups.com 
 /var/autofs/misc/home/jan/.sage/ipython-2.1.0/Sage_crash_report.txt

 To ensure accurate tracking of this issue, please file a report about it
 at:
 http://trac.sagemath.org

 Hit Enter to quit (your terminal may close):
 1 jan@muizenberg:/var/autofs/misc/home/jan$ls
 /usr/lib/sagemath/local/lib/libcsage.so
 /usr/lib/sagemath/local/lib/libcsage.so


 Attached the error file which says cannot find libcsage.so.

 Any ideas?

 Regards,
 Jan

 --
   .~.
   /V\ Jan Groenewald
  /( )\www.aims.ac.za
  ^^-^^

  --
 You received this message because you are subscribed to the Google Groups
 sage-devel group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to sage-devel+unsubscr...@googlegroups.com.
 To post to this group, send email to sage-devel@googlegroups.com.
 Visit this group at http://groups.google.com/group/sage-devel.
 For more options, visit https://groups.google.com/d/optout.




-- 
  .~.
  /V\ Jan Groenewald
 /( )\www.aims.ac.za
 ^^-^^

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: pyopenssl

2014-09-09 Thread kcrisman


On Tuesday, September 9, 2014 3:02:08 AM UTC-4, Jan Groenewald wrote:

 Hi

 I'm running Ubuntu 14.04 and the PPA which is the downloaded binary.

 I wanted to enable notebook(secure=True), which prompted me to install 
 pyopenssl.

 sage -i pyopenssl successfully installed but prompted me to make.


I wouldn't be surprised if this was because of the make and not sage 
-b.  And one should be able to use optional packages with the binary. 

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: Tracking Citations; How?

2014-09-09 Thread Volker Braun
On Monday, September 8, 2014 6:32:33 PM UTC+1, Nils Bruin wrote:

 There is an advantage to a decorator on python-level: If you're happy to 
 configure sage_citation_enabled at start-up (which means it would have to 
 be a command line option or an environment variable), you can make it 
 completely *zero* penalty at runtime, with a little penalty at function 
 definition (import) time:


But that doesn't work at the C level, you either compile something in or 
not. So you can't apply it to the (presumably) speed-critical c(p)def 
functions, only to plain Python functions where overhead wasn't much of an 
issue to start with.

Also, in terms of user experience it is much preferable to have the 
citation tracking switchable at runtime.

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Re: pyopenssl

2014-09-09 Thread Jan Groenewald
Hi

Then perhaps this message should be changed?

$sage -i pyopenssl
...
...
Successfully installed pyopenssl-0.13.p0
Deleting temporary build directory
/home/jan/src/sage-6.3/local/var/tmp/sage/build/pyopenssl-0.13.p0
Finished installing pyopenssl-0.13.p0.spkg

Warning: it might be needed to update the Sage library before
installed packages work: you should run 'make' from $SAGE_ROOT
before running Sage.
0 jan@yae-desktop:~/src/sage-6.3$

Regards,
Jan


On 9 September 2014 14:20, kcrisman kcris...@gmail.com wrote:



 On Tuesday, September 9, 2014 3:02:08 AM UTC-4, Jan Groenewald wrote:

 Hi

 I'm running Ubuntu 14.04 and the PPA which is the downloaded binary.

 I wanted to enable notebook(secure=True), which prompted me to install
 pyopenssl.

 sage -i pyopenssl successfully installed but prompted me to make.


 I wouldn't be surprised if this was because of the make and not sage
 -b.  And one should be able to use optional packages with the binary.

 --
 You received this message because you are subscribed to the Google Groups
 sage-devel group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to sage-devel+unsubscr...@googlegroups.com.
 To post to this group, send email to sage-devel@googlegroups.com.
 Visit this group at http://groups.google.com/group/sage-devel.
 For more options, visit https://groups.google.com/d/optout.




-- 
  .~.
  /V\ Jan Groenewald
 /( )\www.aims.ac.za
 ^^-^^

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: Tracking Citations; How?

2014-09-09 Thread Nils Bruin
On Tuesday, September 9, 2014 5:48:59 AM UTC-7, Volker Braun wrote:

 But that doesn't work at the C level, you either compile something in or 
 not. So you can't apply it to the (presumably) speed-critical c(p)def 
 functions, only to plain Python functions

True 

 where overhead wasn't much of an issue to start with.

 
Don't  underestimate the importance of reasonable performance at python 
level. In for instance magma, the first version of a program often has 
decent performance (at least in my experience), where decent means: I 
can easily do an example in the range of interest. In sage, I have never 
had that. You can use cython to get *great* performance, but at the expense 
of putting in significant work (unwrapping all the convenient sage-layers 
of things, making sure you avoid category overhead, etc). I think it's 
important to have decent performance from the get-go, because that often 
means you don't have to bother putting in 5 extra days of optimizing code 
to do the example you're interested in. 

I'm not sure whether the tests involved with this would lead to a 
significant slow-down, but these things add up. With profiling sage code, I 
have often noticed that there's not a single bottleneck. It's just death 
by thousand cuts. It seems to me this might add another cut at python 
level. In python, looking up a global flag is going to be relatively slow, 
because, if addressed by its proper name, it involves checking several 
__dict__s. This adds noticeably to the overhead:

sage.misc.sageinspect.cite_enabled = False #just borrowing some spot
def citetest(a): pass
sage.misc.sageinspect.citetest = citetest #to compare symbol lookup with 
call overhead

def t1(a):
if sage.misc.sageinspect.cite_enabled:
print cite
return 2*a

def t2(a):
return 2*a

def t3(a):
sage.misc.sageinspect.citetest(citation)
return 2*a   

sage: %timeit t1(20)
100 loops, best of 3: 675 ns per loop
sage: %timeit t2(20)
100 loops, best of 3: 396 ns per loop
sage: %timeit t3(20)
100 loops, best of 3: 797 ns per loop

Unlike a cdef cite_enabled flag on cython level, testing the flag on 
python level is quite noticeable. I'd suspect that cythonizing the process 
would still be comparable, due to the symbol lookup required for finding 
the cythonized routine.

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: Tracking Citations; How?

2014-09-09 Thread Volker Braun
On Tuesday, September 9, 2014 4:44:33 PM UTC+1, Nils Bruin wrote:

 In python, looking up a global flag is going to be relatively slow, 
 because, if addressed by its proper name, it involves checking several 
 __dict__s


Which is why it needs to be a cdef bool as I wrote earlier.

 sage: sage: cython(
: cdef bint sage_citation_enabled = False
: cpdef cite():
: if sage_citation_enabled:
: raise NotImplementedError()
: )
sage: def t2(a):
: return 2*a
: 
sage: def t4(a):
: cite()
: return 2*a
: 
sage: timeit('t2(20)', number=10)
10 loops, best of 3: 360 ns per loop
sage: timeit('t4(20)', number=10)
10 loops, best of 3: 377 ns per loop

Not really noticable any more, especially considering that multiplying-by-2 
is a) something that really should be implented in Cython to avoid Python 
overhead and b) not something that you would cite anyways.

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Re: #16577: enable 0-based row/column permutation of matrices

2014-09-09 Thread Nicolas M. Thiery
On Fri, Sep 05, 2014 at 05:00:29PM +0200, Nathann Cohen wrote:
 I just had a quick look at it, and the following looks downright
scary:
It is one of this code's many wonders. Also, note that :
sage: Permutation([1,2,3])
[1, 2, 3]
sage: Permutation((1,2,3))
[2, 3, 1]
I hate that code.

So do I. However this has nothing to do with the ticket at hand which
is about how *permutation group elements* act on matrices:

Permute the rows and columns of ``self`` by applying the
permutation group elements ``row_permutation`` and
``column_permutation`` respectively.

I'd like to have feedback on that part.

Cheers,
Nicolas
--
Nicolas M. Thiéry Isil nthi...@users.sf.net
http://Nicolas.Thiery.name/

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] git trac log

2014-09-09 Thread Clemens Heuberger
I get (git-trac-command at 7e8fb34)

$ git trac log 16538
Error: release manager has not merged Trac #16538
$ git trac log 16943
Error: release manager has not merged Trac #16943
$ git trac log 16786
Error: release manager has not merged Trac #16786

Actually, #16538 has been merged in 6.4.beta0,
#16943 is closed, but not in a published develop branch,
#16786 is needs_review.

The error message is given without the usual delay incurred when contacting the
trac server:

$ time git trac log 16943
Error: release manager has not merged Trac #16943

real0m0.112s
user0m0.069s
sys 0m0.018s

compared to

$ time git trac print 16943
...
real0m1.070s
user0m0.057s
sys 0m0.014s

All of the above: Linux Mint 13 Maya, 3.13.0-32-generic #57~precise1-Ubuntu

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: #16577: enable 0-based row/column permutation of matrices

2014-09-09 Thread Nicolas M. Thiery
On Fri, Sep 05, 2014 at 07:58:30AM -0700, Dima Pasechnik wrote:
I just had a quick look at it, and the following looks downright scary:

+For backward compatibility, if a permutation group element
+acts on the integers `\{1,\ldots,n\}` or a subset thereof,
+the columns are considered as being numbered from `1`::
+
+sage: G = PermutationGroup(['(1,2,3)(4,5)',
'(1,2,3,4,5)'])
+sage: sigma, tau = G.gens()
+sage: sigma
+(1,2,3)(4,5)
+sage: M = copy(N)
+sage: M.permute_columns(sigma)
+sage: M
+[1 0 1 0 0]
+[2 2 0 0 0]
+[0 3 0 0 3]
+[0 0 0 4 4]
+[0 0 0 5 0]
note that there is an unpleasant ambiguity here:
namely, if, say in this example you take
G = PermutationGroup(['(1,2,3)'])
how one could tell whether it is meant to permute stuff in [0..2], or
in [1..3] ?
Do you mean that one must write G = PermutationGroup(['(0),(1,2,3)'])
for the latter?

I agree it's not great. But do you have a better proposal?

The current situation is a painful source of confusion, and is
actually already ambiguous if one is not reading the specifications
carefully: in your above example, the unwary user may well expect that
he will permute stuff in [1..3].

The ticket only adds a new feature allowing for the natural 0-based
permutations. Otherwise it does not change the current behavior.

Cheers,
Nicolas
--
Nicolas M. Thiéry Isil nthi...@users.sf.net
http://Nicolas.Thiery.name/

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Re: [sage-release] You don't really think that Sage has failed, do you? (a comment about it)

2014-09-09 Thread Nicolas M. Thiery
Bonjour Bernard,

On Wed, Sep 03, 2014 at 12:42:51PM -0700, parisse wrote:
I'm reading the european grant project description on
https://github.com/sagemath/grant-europe/ and I have no idea whether
the software would be free or not. In fact since the project in its
current state is asking more than half of the money for software
engineers mostly for implementing non mathematical aspects, I'm afraid
it would end up developping non-free software around sage, more or less
like the SMC.

Thanks for pointing this out. No worry, I'll never ever get deeply
involved in a grant where not all produced code is open source :-)
Cherry on the cake: on that particular call, it's written explicitly
that the delivered code (and data! and publications!) shall be open.

I'll clarify this on the project page.

Cheers,
Nicolas
--
Nicolas M. Thiéry Isil nthi...@users.sf.net
http://Nicolas.Thiery.name/

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: #16577: enable 0-based row/column permutation of matrices

2014-09-09 Thread 'Martin R' via sage-devel


 The ticket only adds a new feature allowing for the natural 0-based 
 permutations. Otherwise it does not change the current behavior.


But why shouldn't the current behaviour be deprecated?  I think requiring 
that the domain is 0..n-1 (is possible, with a check) would be much better.

Martin

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: git trac log

2014-09-09 Thread Volker Braun
The git trac log ticket only inspects the log of the current branch 
(just like git log, except that it understands trac ticket numbers). So 
you need to be on a sufficiently recent branch if you want the log of these 
tickets.


On Tuesday, September 9, 2014 5:56:28 PM UTC+1, Clemens Heuberger wrote:

 I get (git-trac-command at 7e8fb34) 

 $ git trac log 16538 
 Error: release manager has not merged Trac #16538 
 $ git trac log 16943 
 Error: release manager has not merged Trac #16943 
 $ git trac log 16786 
 Error: release manager has not merged Trac #16786 

 Actually, #16538 has been merged in 6.4.beta0, 
 #16943 is closed, but not in a published develop branch, 
 #16786 is needs_review. 

 The error message is given without the usual delay incurred when 
 contacting the 
 trac server: 

 $ time git trac log 16943 
 Error: release manager has not merged Trac #16943 

 real0m0.112s 
 user0m0.069s 
 sys0m0.018s 

 compared to 

 $ time git trac print 16943 
 ... 
 real0m1.070s 
 user0m0.057s 
 sys0m0.014s 

 All of the above: Linux Mint 13 Maya, 3.13.0-32-generic 
 #57~precise1-Ubuntu 


-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: #16577: enable 0-based row/column permutation of matrices

2014-09-09 Thread Volker Braun
On Tuesday, September 9, 2014 6:07:49 PM UTC+1, Nicolas M. Thiéry wrote:

 I agree it's not great. But do you have a better proposal? 


How about being explicit, aka the principle of least astonishment? 
M.permute_columns(sigma, base=0) with base=1 being the default. In either 
case an error is raised if the range does not fit. Once we have separate 
0-based permutations we can make the default = do the right thing and 
deprecate the optional parameter.

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: Tracking Citations; How?

2014-09-09 Thread Nils Bruin
On Tuesday, September 9, 2014 8:55:04 AM UTC-7, Volker Braun wrote:

 On Tuesday, September 9, 2014 4:44:33 PM UTC+1, Nils Bruin wrote:

 In python, looking up a global flag is going to be relatively slow, 
 because, if addressed by its proper name, it involves checking several 
 __dict__s


 Which is why it needs to be a cdef bool as I wrote earlier.


Yes, but that's not the overhead I referred to. It's the fact that cite 
itself would live somewhere deep in the sage namespace and that the 
canonical way of referring to it would require several dictionary lookups. 
Compare:

cython(
cdef bint sage_citation_enabled = False
cpdef cite():
if sage_citation_enabled:
raise NotImplementedError()
)

sage.misc.sageinspect.cite=cite #borrowing namespace here

def t2(a):
return 2*a

def t4(a):
sage.misc.sageinspect.cite()
return 2*a

sage: sage: timeit('t2(20)', number=1000)
1000 loops, best of 3: 302 ns per loop
sage: sage: timeit('t4(20)', number=1000)
1000 loops, best of 3: 457 ns per loop

On this trivial example it is now quite noticeable. Doing a from 
sage.citation import cite would alleviate this quite a bit as you show, 
but generally from ... import ... is discouraged in favour of leaving 
namespaces intact.  

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Re: #16577: enable 0-based row/column permutation of matrices

2014-09-09 Thread Nicolas M. Thiery
On Tue, Sep 09, 2014 at 10:18:29AM -0700, 'Martin R' via sage-devel wrote:
But why shouldn't the current behaviour be deprecated?

With this ticket I was aiming for a minimal change. If there is a
consensus that we eventually want to get rid of using 1-based
permutations for row/column matrix operations, yes, I am definitely in
favor of deprecating it. Volker's explicit base argument is a
good approach for the transition period.

Cheers,
Nicolas
--
Nicolas M. Thiéry Isil nthi...@users.sf.net
http://Nicolas.Thiery.name/

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Atomic writing in sage-preparse (#16827) needs review

2014-09-09 Thread Jeroen Demeyer

Hello sage-devel,

could somebody please review the small patch
http://trac.sagemath.org/ticket/16827

It fixes the sage-preparse script, which is called when running a 
foo.sage file through the command line, to use atomic_write. This avoids 
race conditions when multiple Sage sessions are run in parallel.


I have been using this patch since several weeks for actual research 
problems, running many Sage sessions in parallel on a multi-core machine 
and I haven't seen any problems (without the patch, sometimes the 
preparsed .py file would be empty for example when executed).


Thanks,
Jeroen.

--
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Re: #16577: enable 0-based row/column permutation of matrices

2014-09-09 Thread Volker Braun
For the record, I'd rather have both 0 and 1-based permutations act on 
matrices in the the natural way (as permutations on an ordered set, 
regardless of how that set is written). So there is no need to get rid of 
1-based permutations. However, we need to be able to tell 0- and 1-based 
permutations apart with certainty before we can fix permute_columns() to do 
the right thing (TM).



On Tuesday, September 9, 2014 9:44:00 PM UTC+1, Nicolas M. Thiéry wrote:

 With this ticket I was aiming for a minimal change. If there is a 
 consensus that we eventually want to get rid of using 1-based 
 permutations for row/column matrix operations, yes, I am definitely in 
 favor of deprecating it. Volker's explicit base argument is a 
 good approach for the transition period. 


-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Memory leak in evaluating polynomials over finite fields

2014-09-09 Thread Volker Braun
I was dabbling in arithmetic when I noticed that the following leaks memory 
at about a megabyte per second:

F.a = GF(11^2, 'a')
R.x, y = F[]
while True:
_ = x(a, a)

Now I would have thought that evaluating polynomials is a fairly common 
operation, so I'm sure somebody noticed this before? Is there a ticket (I 
didn't find one)? Notice that it depends on both the givaro backend for 
finite fields and multi-variate polynomials. 

def leak(n):
import gc
gc.collect()
old = gc.get_objects()
for i in range(n):
_ = x(a, a)# leak memory
gc.collect()
new = gc.get_objects()
return len(new) - len(old)

always returns 1 so the leak is not in Python objects.

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Sage Days 64

2014-09-09 Thread Anne Schilling
Dear All!

Dan Bump, Travis Scrimshaw and I are going to organize Sage Days 64 (=2^6 !!)
at UC Davis March 17-20, 2015. A preliminary website can be found here

http://wiki.sagemath.org/days64

If you are interested in participating, please sign up on the wiki or
drop us a line!

Hope to see you there,

Anne, Dan, Travis

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: [sage-combinat-devel] Sage Days 64

2014-09-09 Thread Paul-Olivier Dehaye
Dear Anne,

 2^6
4

Sincerely,
Paul


Paul-Olivier Dehaye
SNF Assistant Professor of Mathematics
University of Zurich
http://user.math.uzh.ch/dehaye/contact_info.txt

On Wed, Sep 10, 2014 at 2:42 AM, Anne Schilling a...@math.ucdavis.edu
wrote:

 Dear All!

 Dan Bump, Travis Scrimshaw and I are going to organize Sage Days 64 (=2^6
 !!)
 at UC Davis March 17-20, 2015. A preliminary website can be found here

 http://wiki.sagemath.org/days64

 If you are interested in participating, please sign up on the wiki or
 drop us a line!

 Hope to see you there,

 Anne, Dan, Travis

 --
 You received this message because you are subscribed to the Google Groups
 sage-combinat-devel group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to sage-combinat-devel+unsubscr...@googlegroups.com.
 To post to this group, send email to sage-combinat-de...@googlegroups.com.
 Visit this group at http://groups.google.com/group/sage-combinat-devel.
 For more options, visit https://groups.google.com/d/optout.


-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Re: [sage-combinat-devel] Sage Days 64

2014-09-09 Thread kcrisman


 2^6
 4


I didn't know sage-combinat had switched back to pure Python... 

-- 
You received this message because you are subscribed to the Google Groups 
sage-devel group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.