Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃摎 API : make sure the API remains Exojax compatible #597

Open
erwanp opened this issue Aug 1, 2023 · 5 comments
Open

馃摎 API : make sure the API remains Exojax compatible #597

erwanp opened this issue Aug 1, 2023 · 5 comments
Labels
todo in the short-term roadmap

Comments

@erwanp
Copy link
Member

erwanp commented Aug 1, 2023

馃挱 Description

Since #480 Radis embeds a common API shared by Radis-Line-by-line (spectrum calculation code) and Exojax

We should add tests in the Radis CI to make sure the API always remains fully compatible with Exojax functions (in terms of signature, i.e. input parmaters ).

I see it as :

  • in the develop branch, add classes representatives of how Exojax uses the API ; and make sure it works
  • before each new merge to the Master branch, add in our Travis-CI test suite a full installation & test of Exojax

@HajimeKawahara @YuiKasagi any idea / request on this ?

@erwanp erwanp added the todo in the short-term roadmap label Aug 1, 2023
@erwanp erwanp changed the title 馃摎 API : make sure the API is Exojax compatible 馃摎 API : make sure the API remains Exojax compatible Aug 1, 2023
@HajimeKawahara
Copy link
Collaborator

This is a bit difficult problem but important for long time development. Writing some test code for api.py in ExoJAX, and importing these tests to radis? In general, writing the unit tests for database I/O is a bit challenging because it sometimes needs to be downloaded from the database websites.

@erwanp
Copy link
Member Author

erwanp commented Aug 11, 2023

Yes. Do you already have some unitests in Exojax/api? I can borrow them and add them in Radis.api to ensure backward compatibility

@HajimeKawahara
Copy link
Collaborator

HajimeKawahara commented Jan 14, 2024

back to this issue. See exojax #462
Maybe you are right. We need to make the unittest of ExoJAX/api in exojax?
One thing I need to know is about making the unittests independent of the status of the ExoMol site. In other words, I want to avoid downloading from ExoMol. In exojax, we are using mock data for this purpose. How is this being handled in radis?

@erwanp
Copy link
Member Author

erwanp commented Jan 14, 2024

We do 2 things :

from radis.test.utils import getTestFile
from radis import load_spec
load_spec(getTestFile('CO_Tgas1500K_mole_fraction0.01.spec'))

These are very small files, shipped with Radis, usually used to ensure I/O compatibility

@HajimeKawahara
Copy link
Collaborator

Thanks. It looks there is no ExoMol fragment file available in radis.test.utils.getTestFile. Then, I will use a fragment ExoMol file in exojax.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
todo in the short-term roadmap
Projects
None yet
Development

No branches or pull requests

2 participants