SasView / sasmodels

Package for calculation of small angle scattering models using OpenCL.
BSD 3-Clause "New" or "Revised" License
15 stars 27 forks source link

Remove all references to ~/.sasview and ~/.sasmodels in the code. #519

Open pkienzle opened 2 years ago

pkienzle commented 2 years ago

When using sasmodels as a library leave the plugin model path unconfigured. Redirect all caches to use the same caching infrastructure as pyopencl, but in a sister "sasmodels" cache directory. Document control variables which set the cache directories so that users can find and override.

The main point of this exercise is to avoid the confusion of having a ~/.sasmodels directory and a ~/.sasview directory doing similar things.

We could perhaps default the user model directory to ~/.sasview/plugin_models as (almost) suggested by #428 since that is only reading models but we should never be writing to the ~/.sasview directory unless the user explicitly configures sasmodels to do so. See #433 for further discussion.

lucas-wilkins commented 2 years ago

The issue here, at first glance, seems to be that the plugins are considered to be part of sasview, when really they're plugins for sasmodels. As there's no sasview without sasmodels, I would suggest the proper place for plugin handling is in/via sasmodels.

There's a slight naming issue, in that sasview is the name of both the application in general, and the sasview gui interface. It might make some sense to mirror the whole project structure in the directory system. i.e. have .sasview/sasview and .sasview/sasmodels - or even think of a new name for the base directory.