[Numpy-discussion] Re: I need help on the issue of replacing the original C math library with an external C math library

2022-08-12 Thread matti picus
Sorry for the late reply, this ended up in my SPAM filter. I think
google does not like your qq.com domain.

The best way to manage blas/lapack implementations right now is via
the site.cfg file, the example site.cfg.example has extensive
instructions. If it is not working as expected, please share what you
have so far so we can help you, it may be a simple typo.
Matti

On Tue, Aug 2, 2022 at 3:42 PM <454626...@qq.com> wrote:
>
> Hello developers,
> The external math library contains some dynamic link libraries of C language 
> (.so files) and some C header files (.h files), I am tring to link my custom 
> library to NumPy and replace the original bottom math library. I need to add 
> several compile options to the C compiler (gcc etc.), but I have not found 
> the corrosponding part of NumPy source code.
> Merely modifying 'site.cfg' does not work at all, and then adding lib and 
> include directory to '~/numpy/distutils/system_info.py' still does not work. 
> When compiling NumPy source code, it gives a fatal error: myBLAS.h: No such 
> file or directory.
> My doubts: Which code file should I focus on? How to modify configurations 
> and add compile options like '-I /path/to/includes -L /path/to/libs -lmyBLAS'?
> Could you please give me a hint? Looking forward to your reply.
> Thanks!
> ___
> NumPy-Discussion mailing list -- numpy-discussion@python.org
> To unsubscribe send an email to numpy-discussion-le...@python.org
> https://mail.python.org/mailman3/lists/numpy-discussion.python.org/
> Member address: matti.pi...@gmail.com
___
NumPy-Discussion mailing list -- numpy-discussion@python.org
To unsubscribe send an email to numpy-discussion-le...@python.org
https://mail.python.org/mailman3/lists/numpy-discussion.python.org/
Member address: arch...@mail-archive.com


[Numpy-discussion] should random.standard_t allow df=inf?

2022-08-12 Thread Sam Mason
Hi,
I've just stumbled across a somewhat strange behaviour when I evaluated:

  np.random.standard_t(np.inf)

and got NaN back. The limit of df going to infinity in Student's
t-distribution is a Gaussian, so I'd expect a Gaussian variate back
(but I suppose a warning or error could be argued to be valid).  Note
that R explicitly supports this[1] and results in Gaussian
behaviour[2].

It looks relatively easy to modify random_standard_t (in
distributions.c) to get similar behaviour, but wanted to check if this
behaviour was deliberate before opening an issue.

In fact it looks like the precision of doubles limit df > ~1e35 to be
Gaussian[3], which might compile down to something smaller than a call
to isfinite() as well as catching more cases[4].

Thanks!

  Sam

[1] https://search.r-project.org/R/refmans/stats/html/TDist.html
[2] R source, src/nmath/rt.c, src/nmath/dt.c, etc.
[3] np.random.gamma(1e35, size=100) - 1e35
[4] https://godbolt.org/z/KcvY8sKd3
___
NumPy-Discussion mailing list -- numpy-discussion@python.org
To unsubscribe send an email to numpy-discussion-le...@python.org
https://mail.python.org/mailman3/lists/numpy-discussion.python.org/
Member address: arch...@mail-archive.com


[Numpy-discussion] Documentation Team meeting - Monday August 15 at 2pm UTC

2022-08-12 Thread Melissa Mendonça
Hi all!

Our next Documentation Team meeting will happen on *Monday, August 15*
at ***2PM
UTC***.

All are welcome - you don't need to already be a contributor to join. If
you have questions or are curious about what we're doing, we'll be happy to
meet you!

If you wish to join on Zoom, use this link:

https://zoom.us/j/96219574921?pwd=VTRNeGwwOUlrYVNYSENpVVBRRjlkZz09

Here's the permanent hackmd document with the meeting notes (still being
updated):

https://hackmd.io/oB_boakvRqKR-_2jRV-Qjg


Hope to see you around!

* You can also visit https://scientific-python.org/calendars to add the
NumPy community calendar as an .ics file to your preferred calendar manager

- Melissa
___
NumPy-Discussion mailing list -- numpy-discussion@python.org
To unsubscribe send an email to numpy-discussion-le...@python.org
https://mail.python.org/mailman3/lists/numpy-discussion.python.org/
Member address: arch...@mail-archive.com