Re: [sage-devel] Re: polybori: new boost version gives different random values
Hi everybody! Actually because in sage-on-gentoo we use the system boost we hit that particular doctest failure a long time ago. I then asked Alexander Dreyer who works on polybori if the output was ok and it didn't seem to be concerned. Indeed, you can safely ignore the changes in the random output, since these are just user functions for generating random elements. But maybe one could test for the following assumed properties: result = random_set(monomial, n) should obey len(result) == 1 and result.diff(monomial.divisors()).empty() Best regards, Alexander -- 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?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: polybori: new boost version gives different random values
On Feb 27, 9:39 am, Timo Kluck tkl...@gmail.com wrote: The issue is that we're upgrading boost, and apparently, its random number generator has slightly changed. Therefore, we have some failing doctests for random_set. Do we really want to test our random number generators for deterministic behaviour? If so, the test should probably at least set the seed prior to testing things that depend on actual values produced. Of course, if the algorithm used for the pseudo-random generator has actually changed, setting the seed would not be enough, but that should be rare. The more appropriate thing might be to rewrite the test to check general behaviour rather than rely on exact output. -- 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?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: polybori: new boost version gives different random values
Hi Nils, On 2013-02-27, Nils Bruin nbr...@sfu.ca wrote: On Feb 27, 9:39 am, Timo Kluck tkl...@gmail.com wrote: The issue is that we're upgrading boost, and apparently, its random number generator has slightly changed. Therefore, we have some failing doctests for random_set. Do we really want to test our random number generators for deterministic behaviour? If so, the test should probably at least set the seed prior to testing things that depend on actual values produced. Isn't this the case already? In doctests, one can assume that the output of our random number generators is deterministic. Of course, if the algorithm used for the pseudo-random generator has actually changed, setting the seed would not be enough, but that should be rare. If I understand correctly, that rare situation occurs here. Hence, one can still rely on deterministic output, but a *different* deterministic output. The more appropriate thing might be to rewrite the test to check general behaviour rather than rely on exact output. +1 Testing against theorems (such as: One has random data, but the test is using an identity that must hold for any data) is most elegant. Cheers, SImon -- 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?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: polybori: new boost version gives different random values
Op woensdag 27 februari 2013 20:19:32 UTC+1 schreef Simon King het volgende: Hi Nils, On 2013-02-27, Nils Bruin nbr...@sfu.ca javascript: wrote: Do we really want to test our random number generators for deterministic behaviour? If so, the test should probably at least set the seed prior to testing things that depend on actual values produced. Isn't this the case already? In this case, it is. The random number seed is even explicitly set (to 1337) in the doctest itself. Of course, if the algorithm used for the pseudo-random generator has actually changed, setting the seed would not be enough, but that should be rare. If I understand correctly, that rare situation occurs here. Hence, one can still rely on deterministic output, but a *different* deterministic output. Exactly. The more appropriate thing might be to rewrite the test to check general behaviour rather than rely on exact output. +1 Testing against theorems (such as: One has random data, but the test is using an identity that must hold for any data) is most elegant. I agree. I don't know much about polybori though, so I can't really change those doctests in that way. My question is mostly: I assess the situation as being such as you describe above: there is a rare situation where we should accept finding different, yet deterministic, output. However, maybe a polybori expert might correct me and say that this random_set function is often used in such a way that it is vital that it stays backward compatible. I have a hard time imagining that, but I'd better be safe than sorry. It would be great if someone who actually knows what anyone would want to use random_set for, to give us the go-ahead. Best, Timo -- 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?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] Re: polybori: new boost version gives different random values
On Wed, 27 Feb 2013 15:19:34 Timo Kluck wrote: Op woensdag 27 februari 2013 20:19:32 UTC+1 schreef Simon King het volgende: Hi Nils, On 2013-02-27, Nils Bruin nbr...@sfu.ca javascript: wrote: Do we really want to test our random number generators for deterministic behaviour? If so, the test should probably at least set the seed prior to testing things that depend on actual values produced. Isn't this the case already? In this case, it is. The random number seed is even explicitly set (to 1337) in the doctest itself. Of course, if the algorithm used for the pseudo-random generator has actually changed, setting the seed would not be enough, but that should be rare. If I understand correctly, that rare situation occurs here. Hence, one can still rely on deterministic output, but a *different* deterministic output. Exactly. The more appropriate thing might be to rewrite the test to check general behaviour rather than rely on exact output. +1 Testing against theorems (such as: One has random data, but the test is using an identity that must hold for any data) is most elegant. I agree. I don't know much about polybori though, so I can't really change those doctests in that way. My question is mostly: I assess the situation as being such as you describe above: there is a rare situation where we should accept finding different, yet deterministic, output. However, maybe a polybori expert might correct me and say that this random_set function is often used in such a way that it is vital that it stays backward compatible. I have a hard time imagining that, but I'd better be safe than sorry. It would be great if someone who actually knows what anyone would want to use random_set for, to give us the go-ahead. Actually because in sage-on-gentoo we use the system boost we hit that particular doctest failure a long time ago. I then asked Alexander Dreyer who works on polybori if the output was ok and it didn't seem to be concerned. You can give him a ping for his opinion. Martin Albretch could also be contacted. Francois -- 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?hl=en. For more options, visit https://groups.google.com/groups/opt_out.