-
Notifications
You must be signed in to change notification settings - Fork 41
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’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
updated custom models not being recompiled (Trac #576) #708
Comments
Trac update at
|
Trac update at Can force use of DLL rather than OpenCL using the following in the python shell:
|
Trac update at To reproduce, create a custom model using Fitting>Edit Custom Model>New, setting model to e.g.,
You can then use this model on the fit page. When the model is updated, e.g., to:
the new model is not updated. The same is true for C models. Update the model to:
Test model update and reload on mac, windows wt/ opencl and windows wt/ tinycc. |
Trac update at
to:
|
Trac update at OpenCL fixed, DLL fails. To get the DLL to work, first remove the frozen check in sasmodels.kerneldll.make_dll, then restructure the !DllKernel so that it doesn't hold any references to the DLL. Follow the instructions to reproduce above, but with sasmodels.core.HAVE_OPENCL=False. We can do this by wrapping the ct.CDLL in a class with methods for the different kernels. Instead of calling the kernels directly, calls from !DllKernel will go through this object. !DllModel may be could do this if we can guarantee there is only ever one !DllModel instance for a particular dll, for example, by caching !DllModel within load_dll(). Then its internal dll can be released, recompiled and reloaded with any attached kernels automatically updated. |
Trac update at A student I am working with (Windows / no OpenCL) noticed this problem and currently is working round it by deleting the dll to force a rebuild. He also noticed that python models will rebuild if secondary functions are changed, but not if Iq and Iqxy are changed. Which is odd. |
Trac update at Attached model (hexagonal_cylinder.py) is the one that was causing problems - there was different rebuild behaviour between modifying secondary functions (e.g. Reflections() ) vs modifying Iq or Iqxy. |
Trac update at |
Trac update at I did some testing and it seems that python models behave properly (are being updated). This also applies to hexagonal_cylinder.py (at least according to my test). However, the problem still persist if the plugin models have c code sections like: These models don't update but !SasView doesn't crush. So this bug seems to apply to rather limited number of cases (plugins with C code embedded and no OpenCL). I guess it shouldn't affect too many users. Shouldn't we wait with fixing it until full 4.0 is out? |
Trac update at |
Trac update at
As decided at the fortnightly meeting Sep 27, 2016 we feel this is good enough for release 4.0 and it would be dangerous to try to fix the rest 3 days before the final release -- moving to 4.1
|
Trac update at In changeset 9acbd37c401f7d905e67370f7361a35762628e75:
|
Trac update at In changeset 886fa25dbb18c6bb0e504b4c4231771e0f26d910:
|
Trac update at In changeset 5b37fd681b84af2a1adc33b956ca441b19da76fe:
|
Trac update at In changeset 47f2b5d:
|
Trac update at
|
When updating the custom model within sasview on opencl the model doesn't always get updated.
When compiling to a dll, compile fails because dll is already loaded.
Migrated from http://trac.sasview.org/ticket/576
The text was updated successfully, but these errors were encountered: