-
Notifications
You must be signed in to change notification settings - Fork 95
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
[Debugging new models] Any idea of how to expose __device__ void calculate_model() in order to check model implementation? #30
Comments
void LMFitCUDA::simul() |
For debugging purposes, it may be useful to implement the model within Cpufit, first. Then, you can use a standard debugger without having to run the code on the GPU. |
@gittry @superchromix I agree that maybe an additional gpusimul() function could be overkilling ... |
My impression is that it would not be overkill. Cpufit is the simulation of Gpufit in a manner of speaking. What we ideally would like to have is to write down the model once and then use it once on the CPU (for debugging purposes) and once on the GPU without duplicating the code. So far we did not manage to do that and we are duplicating code in the CPU and GPU library versions with all the drawbacks but in a future version this might well be the case. |
Also, just being able to compute the model or the gradients at the current parameters sounds like an obvious enhancement to me. Often enough you not only need the final fit parameters but also the model values at these parameters. Would need to extend the interface for that. We should keep this in mind. |
This would involve copying a large amount of data from the GPU to the CPU, resulting in slower performance. This could possibly be an optional output. |
@superchromix |
So far, the C interface of Gpufit is stateless, so either one would need to add another input flag (controlling outputs) or set this with another function and then Gpufit would need to remember its state. |
I just want to test a new model but despite note having compilation issue, it doesn't fit my data.
I thought of testing my code giving my kernel a set of parameter and checking the shape of the simulated curve but I am having more troubles than expected.
Down here what I tried to do, but it is not working at all ...
The text was updated successfully, but these errors were encountered: