-
-
Notifications
You must be signed in to change notification settings - Fork 431
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
[GSoC 2015 WIP] Testing other montecarlo functions #330
Conversation
@wkerzendorf how should we go about testing the other functions that don't return anything ? |
can you give an example? |
|
@kaushik94 that is a function that does the scatter of the montecarlo particles. What will change is the rpacket. This is some physics - can you make a PR just testing the |
@wkerzendorf oh, In that case I guess all the functions in #295 need to be tested the same way. The trivial functions are tested in this PR. Can this be merged now ? And regarding the rest of the functions, I might need help from @aoifeboyle . @aoifeboyle please let me know a good time for you tomorrow, we can finish all of them off tomorrow. |
@wkerzendorf @kaushik94 I'm not very clear on the montecarlo stuff but I can definitely try! Give me some time to have a look through it here. So should I just devise suitable tests for all of the functions? |
@aoifeboyle - no specifically have a look at |
@wkerzendorf Ok, having a look through it now! |
} | ||
|
||
double | ||
test_compute_distance2electron(){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to test these functions. What should I start testing with ? Can anyone help me with simulating a decent rpacket and a storage model ? @aoifeboyle or @wkerzendorf .
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's quite late here now, but I can help tomorrow @kaushik94 :)
@kaushik94, I think I'll start by creating a test for the montecarlo_line_scatter function as you were planning to. I'm not that clear on C so I think that would be a good exercise to help me understand it. And I'll create an rpacket and storage_model that makes sense in terms of the physics to test it with. Does that sound ok for starters? |
@aoifeboyle that'd be great. |
@aoifeboyle You can just write the specs of rpacket and storage model on a doc somewhere and share it with me, I'll take care of the coding part. What do you think ? |
Hi @kaushik94, sure! I'll create a document on google docs. |
@kaushik94 I've updated our google doc with explanations of all of the parameters you asked for, and a bit of code to let you extract lines data from the atomic datasets for running your tests. Let me know if there is anything that isn't exactly clear! I hope this helps. If you need any other parameters explained, just put them in the google doc and I'll fill in explanations. |
@kaushik94 I added the new values you asked for to the google doc. Ping me next time you add new ones. It doesn't notify me automatically. |
@kaushik94 I got an email saying you'd left a comment here about your tests but I can't see it here - did you remove it? I looked at the tests in |
@aoifeboyle Yeah I mistakenly added a file that caused that error, I fixed it an deleted the comment. Are you getting an error still ? I just committed. The problem was that I din't declare |
Ah ok that's fine! And yeah I don't think it really matters which one you do next. Let me know if there are any more parameters you need me to define :) |
@aoifeboyle see the doc, just updated. |
Hi Kaushik, How are you getting along now? Aoife Sent from Windows Mail From: Kaushik Varanasimailto:[email protected] @aoifeboylehttps://github.com/aoifeboyle see the doc, just updated. Reply to this email directly or view it on GitHubhttps://github.com//pull/330#issuecomment-114842363. |
Hi @aoifeboyle I think I need your help, come on the doc if you are free now. |
I can't. I have to give my sister my laptop for the next hour or so. But I'll have a look at the doc then. Sent from Windows Mail From: Kaushik Varanasimailto:[email protected] Hi @aoifeboylehttps://github.com/aoifeboyle I think I need your help, come on the doc if you are free now. Reply to this email directly or view it on GitHubhttps://github.com//pull/330#issuecomment-116792711. |
@kaushik94 Done! |
@aoifeboyle strange because it seems to me that the problem is in |
/* The following values need to be | ||
* reassigned properly. By default | ||
* I assigned all 0. | ||
*/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aoifeboyle I know this might take a while so sorry. I need some sensible values for the following. You can reply in the doc or even comment them in-line and please explain the terms if you have a little time. I thought of looking up in the atomic data but couldn't find much about the storage models and etc, or if you are busy just let me know where I can get the data elsewhere. Thanks a lot.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kaushik94 Having a look now. Let's try to keep the google doc more tidy (just for storing the parameter details) so it can be a reference for you. Let's keep the conversation on GitHub/email.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kaushik94 They're in the doc now. Most of it wasn't in the atomic data, but I've given you reasonable values (I think). Let me know if you have any more problems.
@kaushik94 Did you see what I wrote about test in the doc? Your test works fine for me. So I don't know why it doesn't work for you? How do you actually run the tests? |
@aoifeboyle yes I saw, it was my mistake. The tests were running sometimes and sometimes fail, because I forgot to declare a function in C file which was giving weird errors. Now it all works fine. Thanks, will take a look at the doc. |
@aoifeboyle thanks, just see if I did everything correctly. |
@wkerzendorf review and merge. |
@kaushik94 it doesn't pass. can you elaborate what doesn't work. |
It works fine on my local. see this https://travis-ci.org/tardis-sn/tardis/jobs/69728700. strange error, says |
I think there is a bug on the travis side or I am doing something terribly wrong. I am trying to debug but please let me know if you understood @wkerzendorf . |
@kaushik94 hmmm - try to clean your working directory with |
Yes it does. On Mon, Jul 6, 2015 at 8:04 PM, Wolfgang Kerzendorf <
|
@wkerzendorf I got the error. Check the storage.h file of the master in github. Someone removed |
@kaushik94 yes that makes sense have a look at #338 that did that to parallelize the code. Can you rebase onto the current master? |
Okay got it. |
@wkerzendorf I am still getting an error |
that's right - it's now called |
@wkerzendorf please review and merge. |
updating master
Please don't merge, more functions to be added. |
@wkerzendorf please merge this. For reference #295 . I have not done testing for |
@wkerzendorf I am getting different answers for |
@wkerzendorf please merge this. But I don't know how to go about from here. A little help is much required. Thanks. |
[GSoC 2015 WIP] Testing other montecarlo functions
@wkerzendorf is this how it should be done ?