ComputationalRadiationPhysics / picongpu

Performance-Portable Particle-in-Cell Simulations for the Exascale Era :sparkles:
https://picongpu.readthedocs.io
Other
691 stars 217 forks source link

Use other alias for `openpmd_api` #4802

Open chillenzer opened 7 months ago

chillenzer commented 7 months ago

I've noticed in #4801 that it seems to be a convention to do

import openpmd_api as io

but I think this is unfortunate because io is a python standard library module which might mislead people more familiar with the Python ecosystem than with PIConGPUs conventions. If nobody complains in the near future, I'll submit a PR changing this into something less ambiguous.

psychocoderHPC commented 7 months ago

ping @PrometheusPi @steindev @ikbuibui @BrianMarre @pordyna What is you opinion?

steindev commented 7 months ago

It is sensible to change this. But it is not a PIConGPU-only convention. The root cause of this unfortunate naming is openPMD's documentation. See (https://openpmd-api.readthedocs.io/en/0.15.2/usage/firstwrite.html#python).

chillenzer commented 7 months ago

Well, I'll open an issue there, too.

pordyna commented 7 months ago

I sometimes do import openpmd_api as api as it used to be earlier in the openpmd docs. Though, I don't think that this is a good option either. We should probably let the openpmd devs discuss it first.

chillenzer commented 6 months ago

As you can see, I've opened the issue over at the openPMD repo. Let's wait for a few days and come back to this, then. Is there a "remind-me-later" button for GH issues?

BrianMarre commented 4 months ago

@chillenzer Reminder ;)

I think

import openpmd_api as opmd

works for our purposes.

chillenzer commented 4 months ago

Yeah, I think that's the way to go. I'll do a final ping in the corresponding OpenPMD issue and set it on my to-do list for PIConGPU. Any final objections, @ComputationalRadiationPhysics/picongpu-maintainers ?

PrometheusPi commented 1 month ago

What's the status of this change @chillenzer?

chillenzer commented 1 month ago

If only, I'd know. =P

It's okay. I'll go ahead and fix it.