Ticket 1265 superball#478
Conversation
|
Math corresponds to code. Analytic function matches MC simulation (I updated realspace to include Superball). Limiting cases produce correct form volume. I don't know why F is not scaled by form_volume in calculating Fq and Iqabc. Is volume somehow incorporated in the leading length_a squared term? Regardless, I was unable to match a polydisperse sphere with a polydisperse superball using: sascomp -highq -single! -nq=100 superball,sphere length_a=100 length_a_pd=0.2 radius=length_a/2 radius_pd=length_a_pd/2 exponent_p=1Using the volume-weighted Fq in the sphere model, the polydispersity distribution is on number density, and this may be the source of the difference. Doc strings could use Could use a |
The group has been contacted to have a look into this issues. |
|
Hello hope ya'll doing fine, great to hear we are thinking about incorporating the code 😄
Actually the volume is included in the numerical integral calculated in the
I tested the command but used
Mhh I think that would be a good idea for some optimization. Substituting |
|
Hi Dominique, Nice to see you back doing science (as long as the German IT stays safe so long). The substitution is already done with the second to last commit. |
|
The remarks of @DomiDre are now also reflected in the model. |
Don't you call any demons on me 😄. I think what Paul meant, was to replace the call of SINCOS by the substitution in the theta integral. I've done it, but sadly don't see any significant speedup to mention. But I guess it looks nicer this way. |
butlerpd
left a comment
There was a problem hiding this comment.
Hi Dominique -- good to hear from you. I was confused by the polydispersity and volume discussion but I agree that you are doing the correct PD and the volume should work (indeed if it didn't you would not get the same answer using 20% polydisperisty.
Given Paul's review I think this should be ready to merge?
|
@DomiDre, you are correct about the pd. It is relative and doesn't need to be scaled. I verified that the limitation to q < 0.65 is due to under sampling in the integrals. You can see this by increasing the number of points in the integral to 76, which (eventually) shows a difference at q=4. First delete I'll put in a ticket to address the speed/accuracy issues. |
|
Hmm, do we know why ubuntu test is failing? |
The issue is fixed and all checks are green. |
|
sasmodels ready for testing on OSX |
|
This time unfortuantely Jenkins's complained: https://jenkins.esss.dk/sasview-beta/job/sasmodels-OSX10.13-ghprb/32/console |
|
sasmodels ready for testing on OSX |
|
@wpotrzebowski I don't understand why the write code is failing for umlauts. Can you try the open/write calls directly on the Jenkins machine to figure out what is going on? |
Hmm, Umlauts seem to work but I am also getting this warning/error: |
|
I've seen this when the image generation code was interrupted. With caching in Lines 363 to 365 in 79e9f4a even the rebuild all in MakefileLines 54 to 56 in 79e9f4a will not attempt to generate the image when the rst file already exists. Either you need to touch superball.py or clear superball.rst from the cache. And maybe check for a zero-length superball png in the image cache.
|
|
sasmodels ready for testing on Win |
|
sasmodels ready for testing on OSX |
|
SOLVED: Deleting the categories.json will create updated categories. There is another issue with updating changes in the model files, that I have encountered. The model should appear under the category "sphere", but an own "superball" category is created. I tested also with other models simply changing the category in the model describtion. The behaviour is similar: the model will stay in the old group and does not switch to the new category. |
|
ready for testing on OSX |
|
sasmodels ready for testing on OSX |
|
Model precision problems are not due to single vs. double. The results compare identically to float32 precision. I have been having problems on Mac with compilers and/or OpenCL drivers. Does it help to use |
According to the discussion we had at the developers meeting we move to GH actions builds, so I guess no need for fixing it on Jenkins... |
|
I don't think we need For example on my mac I had to remove sasmodels/sasmodels/kernel_iq.c Line 129 in 136e632 because the superball branch had an old version. This might have been what was causing the model not to build properly. Similarly, regarding the commit I don't know why the file would exist but not be accessible. And if it isn't accessible, then you probably can't overwrite it. So this is solving a problem that shouldn't exist if you are starting with a clean environment. |
|
This PR is changing a number of files. I think you need to merge master into this branch and check that the diff looks reasonable before merging back into master. |
|
sasmodels ready for testing on OSX |
|
sasmodels ready for testing on Win |
The superball model allows to quantify if a nanoparticle is cuboidal or spherical with a parameter describing the sharpness of corners and edges. The superball form factor allows to differentiate between effects arising due to particle size distribution and the irregular particle shape.