Re: [Numpy-discussion] [SciPy-Dev] Season of Docs - welcome Anne, Maja, Brandon

2019-08-08 Thread Bennet Fauber
I can offer some time for alpha or beta reading and proofreading.

I have experience as a proofreader, copy editor (American Statistical
Association), and mathematical typesetter (Wiley, Academic Press,
Addison-Wesley, et al.).  I've taught statistical software workshops,
(very) introductory python, have a Software Carpentry instructor
certificate, and work daily with people who are finding themselves
needing technical and scientific computing but who don't have strong
backgrounds.  Hopefully that would be good context for early review of
a couple of the projects.

I will add my name to the poll, if that's OK?

-- bennet

On Wed, Aug 7, 2019 at 9:03 PM Ralf Gommers  wrote:
>
>
>
> On Tue, Aug 6, 2019 at 4:46 PM Ralf Gommers  wrote:
>>
>> Hi all,
>>
>> Google has announced the Season of Docs participants for this year [1]. We 
>> had a lot of excellent candidates and had to make some hard choices. We 
>> applied for extra slots, but unfortunately didn't win the lottery for those; 
>> we got one slot for NumPy and one for SciPy. We chose the projects of Anne 
>> for NumPy and Maja for SciPy:
>>
>> Anne Bonner, "Making "The Basics" a Little More Basic: Improving the 
>> Introductory NumPy Sections" [2]
>>
>> Maja Gwozdz, "User-oriented documentation and thorough restructuring" [3]
>>
>> That's not all though. There was some space left in the budget of the NumPy 
>> BIDS grant, and Stéfan has reserved that so we can accept more writers and 
>> provide them the same mentoring and funding as they would have gotten 
>> through GSoD. We could only start the conversations about that once Google 
>> made its decisions, so a further announcement will follow. However, we 
>> already have one extra project confirmed, from Brandon:
>>
>> Brandon David, "Improve the documentation of scipy.stats" (project details 
>> to be published).
>
>
> Happy to announce that we have a fourth participant:
>
> Shekhar Rajak, "numpy.org redesign and high level documentation restructuring 
> for end user focus"
>
> Welcome Shekhar!
>
>> I will send out a poll to find a good time for everyone for a kickoff call. 
>> Our intent is to build a documentation team with multiple writers and 
>> mentors interacting and able to help each other out. And all of this will 
>> also interact with the numpy.org website redesign and the people putting 
>> energy into that:)
>
>
> Here is the poll link: https://doodle.com/poll/skgbk74gsg8zpziu. I hope we 
> can find a time that works for everyone - we're split over all US timezones, 
> Europe and India. So it's going to be early morning or late evening somewhere.
>
> Sending this out in public, so anyone who wants to participate is welcome to 
> join. I've Bcc'd all participants and mentors, to make sure they see this.
>
> Cheers,
> Ralf
>
>
>>
>>
>> I'm very happy to welcome Anne, Maja and Brandon!
>>
>> Cheers,
>> Ralf
>>
>>
>> [1] https://developers.google.com/season-of-docs/docs/participants/
>> [2] 
>> https://developers.google.com/season-of-docs/docs/participants/project-numpy
>> [3] 
>> https://developers.google.com/season-of-docs/docs/participants/project-scipy
>
> ___
> SciPy-Dev mailing list
> scipy-...@python.org
> https://mail.python.org/mailman/listinfo/scipy-dev
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] np.genfromtxt StopIteration Error

2019-10-11 Thread Bennet Fauber
I think genfromtxt() wants a filename as the first argument, and you
have to tell it the entries in the file are strings not numerics.

test.py
--
import os
import glob
import numpy as np

fileList = []
filesList = []

for files in glob.glob("*.log"):
fileName, fileExtension = os.path.splitext(files)
fileList.append(fileName)
filesList.append(files)

print('fileList = ', fileList)
print('filesList = ', filesList)

fname = '/tmp/foo.txt'
print('fname = ', fname)
data = np.genfromtxt(fname, dtype=str)
print(data)
--

Contents of /tmp/foo.txt
--
15-7.log
18-7.log
14-7.log
C-VX3.log
--

Sample run

$ python --version
Python 2.7.15+

$ python t.py
('fileList = ', ['15-7', '18-7', '14-7', 'C-VX3'])
('filesList = ', ['15-7.log', '18-7.log', '14-7.log', 'C-VX3.log'])
('fname = ', '/tmp/foo.txt')
['15-7.log' '18-7.log' '14-7.log' 'C-VX3.log']

Is that any help?


On Fri, Oct 11, 2019 at 12:41 PM Stephen P. Molnar
 wrote:
>
> I have been fighting with the genfromtxt function in numpy for a while now 
> and am trying a slightly different approach.
>
> Here is the code:
>
>
> import os
> import glob
> import numpy as np
>
> fileList = []
> filesList = []
>
> for files in glob.glob("*.log"):
> ?? fileName, fileExtension = os.path.splitext(files)
> ?? fileList.append(fileName)
> ?? filesList.append(files)
>
> print('fileList = ', fileList)
> print('filesList = ', filesList)
>
> fname = filesList
> print('fname = ', fname)
> data = np.genfromtxt(fname, usecols=(1), skip_header=27, skip_footer=1, 
> encoding=None)
> print(data)
>
> np.savetxt('fileList.dG', data, fmt='%12.9f', header='${d}')
> print(data.dG)
>
> I am using the Spyder IDE which has a variable explorer which shows:
>
> filesList = ['C-VX3.log', '18-7.log', '14-7.log', '15-7.log']
> fileList = ['C-VX3', '18-7', '14-7', '15-7']
>
> so the lists that genfromtxt needs are being generated.
>
> Goggling 'numpy genfromtxt stopiteration error' does not seem to address this 
> problem. At least, I didn't find plaything that I thought applied.
>
> I would greatly appreciate some assistance here.
>
> Thanks is advance.
>
> --
> Stephen P. Molnar, Ph.D.
> www.molecular-modeling.net
> 614.312.7528 (c)
> Skype:  smolnar1
>
> ___
> NumPy-Discussion mailing list
> NumPy-Discussion@python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] np.genfromtxt StopIteration Error

2019-10-11 Thread Bennet Fauber
What happens if you use this?

for txtfile in filesList:
data = np.genfromtxt(txtfile, dtype=str, usecols=(1),
skip_header=27, skip_footer=1, encoding=None)
print(data)

That pulls one file name from filesList, stuffs the name into txtfile,
which is then provided to genfromtxt().

The point is that genfromtxt() wants one thing; you have to give it
one thing.  The above gives it one thing, but runs it for however many
things are in the filesList.

Does that help?

On Fri, Oct 11, 2019 at 2:41 PM Stephen P. Molnar
 wrote:
>
> Thanks for the reply.
>
> Keep in mind that i am a Chemist, not an IT person. I used to be a
> marginally proficient FORTRAN II user in the ancient past.
>
> I tried running your code. Please see my comments/questing below:
>
> On 10/11/2019 01:12 PM, Bennet Fauber wrote:
> > I think genfromtxt() wants a filename as the first argument, and you
> > have to tell it the entries in the file are strings not numerics.
> >
> > test.py
> > --
> > import os
> > import glob
> > import numpy as np
> >
> > fileList = []
> > filesList = []
> >
> > for files in glob.glob("*.log"):
> >  fileName, fileExtension = os.path.splitext(files)
> >  fileList.append(fileName)
> >  filesList.append(files)
> >
> > print('fileList = ', fileList)
> > print('filesList = ', filesList
> >
> > fname = '/tmp/foo.txt'
> There is no '/temp/foo.txt' Where did it come from in your example?
> > print('fname = ', fname)
> > data = np.genfromtxt(fname, dtype=str)
> > print(data)
> > --
> >
> > Contents of /tmp/foo.txt
> > --
> > 15-7.log
> > 18-7.log
> > 14-7.log
> > C-VX3.log
> > --
> >
> > Sample run
> I'm using python 3.7.3, should this make a difference?
> >
> > $ python --version
> > Python 2.7.15+
> >
> > $ python t.py
> > ('fileList = ', ['15-7', '18-7', '14-7', 'C-VX3'])
> > ('filesList = ', ['15-7.log', '18-7.log', '14-7.log', 'C-VX3.log'])
> > ('fname = ', '/tmp/foo.txt')
> > ['15-7.log' '18-7.log' '14-7.log' 'C-VX3.log']
> >
> > Is that any help?
> if I use data = np.genfromtxt('14-7.log', dtype=str, usecols=(1),
> skip_header=27, skip_footer=1, encoding=None) with a specific file name.
> in this example 14-7, I get the resutt I desired:
>
> # 14-7
> -9.960902669
> -8.979504781
> -8.942611364
> -8.915523010
> -8.736508831
> -8.663387139
> -8.410739711
> -8.389146347
> -8.296798909
> -8.168454106
> -8.127990818
> -8.127103774
> -7.979090739
> -7.941872682
> -7.900766215
> -7.881485228
> -7.837826485
> -7.815909505
> -7.722540286
> -7.720346742
>
> so, my question is; why the StopIteration error message in my original
> query? Why is the dcrtipt not iterating over the log files?
>
> Sorry to be so dense.
>
>
> >
> > On Fri, Oct 11, 2019 at 12:41 PM Stephen P. Molnar
> >  wrote:
> >> I have been fighting with the genfromtxt function in numpy for a while now 
> >> and am trying a slightly different approach.
> >>
> >> Here is the code:
> >>
> >>
> >> import os
> >> import glob
> >> import numpy as np
> >>
> >> fileList = []
> >> filesList = []
> >>
> >> for files in glob.glob("*.log"):
> >> ?? fileName, fileExtension = os.path.splitext(files)
> >> ?? fileList.append(fileName)
> >> ?? filesList.append(files)
> >>
> >> print('fileList = ', fileList)
> >> print('filesList = ', filesList)
> >>
> >> fname = filesList
> >> print('fname = ', fname)
> >> data = np.genfromtxt(fname, usecols=(1), skip_header=27, skip_footer=1, 
> >> encoding=None)
> >> print(data)
> >>
> >> np.savetxt('fileList.dG', data, fmt='%12.9f', header='${d}')
> >> print(data.dG)
> >>
> >> I am using the Spyder IDE which has a variable explorer which shows:
> >>
> >> filesList = ['C-VX3.log', '18-7.log', '14-7.log', '15-7.log']
> >> fileList = ['C-VX3', '18-7', &#x

Re: [Numpy-discussion] Google Season of Docs Ideas

2020-04-27 Thread Bennet Fauber
I think I would add to this categorization which science 'domain' or
area.  Researchers's needs from agriculture and sociology may differ
much more from each other than educators's and researchers's needs
within those field differ from each other.  So, if there is an
up-and-coming area of study that is just starting to make its presence
felt in the NumPy community, they might be a good target audience, and
they might well be working on material such as what we are looking for
themselves?

On Mon, Apr 27, 2020 at 3:33 PM Ben Nathanson  wrote:
>>
>> NumPy serves many kinds of usersThe challenge: provide ways to guide 
>> those users to the parts of the documentation most relevant to them.
>
>
> I have a thought on how to approach this. We know many of the communities 
> NumPy serves; let's next identify (for ourselves, not the proposal) what each 
> of them needs. It could be as simple as:
>
>   Educator
>
> knows...
> needs to know...
>
>   Researcher
>
> knows...
> needs to know..
>
>
> A table like that would be useful for self-assessment and planning. It helps 
> answer questions like:
>
> Which communities are we most shortchanging right now?
> Which communities do we feel most strongly about (our largest base, most 
> disadvantaged, etc.)?
> If doc D is our next doc, does it help those communities? Or maybe we want to 
> go round-robin through communities with each new doc.
> What assumptions can a writer make about audience background?
>
> We're also then equipped to bring user categories out to a web page and meet 
> the big-tent challenge head-on, with links like:
>
> If you're an educator...
> If you're a researcher...
>
> each one taking the user to an Educator, Researcher,..., page containing 
> links to the information they're most likely to want.
>
> ___
> NumPy-Discussion mailing list
> NumPy-Discussion@python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] Documentation Team Meeting - Monday April 27

2020-05-05 Thread Bennet Fauber
I added a link to the NumPy regression example tutorial I created to
the HackMD document near the bottom of the notes for the last meeting.

It is quite long, a function of it being based on material for several
one-hour, hands-on training sessions for very beginning Python users
(about half the class had used Python for less than two hours) that I
gave over four days.  I try to lay out a bit of the theory, a bit of
making a plan for the project, and some opinions.  I'm sure it would
need to be modified a good deal to fit into the NumPy scheme of
things.  It is definitely a draft.  Hopefully there is something
useful in it.

-- bennet

On Mon, Apr 27, 2020 at 6:51 AM Melissa Mendonça  wrote:
>
> Hi all!
>
> Sorry for the late reminder, but today (April 27) we have another 
> documentation team meeting at 3PM UTC**. If you wish to join on Zoom, you 
> need to use this link
>
> https://zoom.us/j/420005230
>
> Here's the permanent hackmd document with the meeting notes:
>
> https://hackmd.io/oB_boakvRqKR-_2jRV-Qjg
>
> Hope to see you around!
>
> ** You can click this link to get the correct time at your timezone: 
> https://www.timeanddate.com/worldclock/fixedtime.html?msg=NumPy+Documentation+Team+Meeting&iso=20200406T15&p1=1440&ah=1
>
> - Melissa
> ___
> NumPy-Discussion mailing list
> NumPy-Discussion@python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion


[Numpy-discussion] Running numpy.test() after pip install

2021-09-28 Thread Bennet Fauber
I just installed NumPy using pip and Python 3.9.7 on CentOS 7.9.
Installation went fine, but when I ran

>>> import numpy
>>> numpy.test()

I got a traceback, and this summary.

=== short test summary info 
ERROR  - ModuleNotFoundError: No module named 'hypothesis'
 Interrupted: 1 error during collection 

It seems that both hypothesis and pytest are needed to run numpy.test().

We like to be able to run all the tests even after a pip install, and
being able to run some of the tests from pip-installed numpy is useful
as well.

May I suggest you add those two packages as dependencies for NumPy at
PyPi?  Neither are particularly large, both are generally useful, and
I think the potential utility for those who would ike to check on
their own system for anomalies outweighs the minimal impact on the
majority of users who would not use it but would also probably not
notice their presence.

If adding them as dependencies seems to heavy weight, or is otherwised
deemed undesirable, perhaps just a note in the Project Description at
https://pypi.org/project/numpy/ to say that, if you want to run tests,
those two packages will be needed?

Thanks,-- bennet
___
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