Simple way to determine if Jep is built with numpy support?

28 views
Skip to first unread message

Erik J

unread,
Sep 22, 2020, 3:57:42 PM9/22/20
to Jep Project
Hi everyone. We have some existing code that has run fine for several years but broke with a recent SW upgrade. I think it may be that Jep is now installed prior to numpy and therefore does not have numpy support. Is there a simple way to test for this in an existing install? Our symptom is that a PyJArray object that is passed into NDArray() is returned as a PyJObject and not an NDArray. If there is a simple way to confirm the numpy support?

Thanks for any help you can give me,
Erik

Nathan Jensen

unread,
Sep 22, 2020, 5:08:07 PM9/22/20
to Erik J, Jep Project
You should be able to run the jep script at the command line, and then in the interpreter do

import jep
jep.JEP_NUMPY_ENABLED

--
You received this message because you are subscribed to the Google Groups "Jep Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jep-project...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jep-project/19e0cad0-2035-4400-afc3-9582cdb422fdn%40googlegroups.com.

Erik Johansson

unread,
Sep 23, 2020, 2:10:37 PM9/23/20
to Jep Project
Sorry, forgot to reply-all:

Thanks, Nathan! That confirmed the problem:

>>> import jep
>>> jep.JEP_NUMPY_ENABLED
0
>>> 

Erik

--
************************************************
Erik Johansson
Project Manager, Wavefront Correction System
National Solar Observatory
Daniel K Inouye Solar Telescope
3665 Discovery Drive, Boulder, CO 80303
Tel: 303-735-7723
************************************************

Erik J

unread,
Sep 23, 2020, 2:36:05 PM9/23/20
to Jep Project
Hi everyone,

I'm posting this in case someone else runs into the same problem. Our install process switched to using pip with a requirements.txt file. It turns out that even though Jep was the last package in the list, it got built first and a wheel was created, before numpy was installed. Hence, the Jep installation did not include support for numpy, which broke codes that ran fine previously. We have solved the problem by removing Jep from the requirements list and into its own requirements file and installing it after the other requirements are installed.

Regards,
Erik

Reply all
Reply to author
Forward
0 new messages