Search found 10 matches

by mikemike10212003
Sat Jan 20, 2018 4:08 pm
Forum: User discussion
Topic: How to use magma_*customspmv in the program?
Replies: 8
Views: 3377

Re: How to use magma_*customspmv in the program?

Dear Hartwig, I use the function pointer to handle these things. I also add Magma_USERSPMV = 633 in magma_storage_t and Magma_USERPRECOND = 430 in magma_solver_type for using them in wrapper. USERSPMV will use userkernel to store the variables and userspmv to get the function. USERPRECOND will also ...
by mikemike10212003
Sun Nov 12, 2017 1:56 pm
Forum: User discussion
Topic: How to use magma_*customspmv in the program?
Replies: 8
Views: 3377

Re: How to use magma_*customspmv in the program?

Dear Hartwig,
Thanks a lot!
Mike
by mikemike10212003
Tue Nov 07, 2017 7:52 am
Forum: User discussion
Topic: How to use magma_*customspmv in the program?
Replies: 8
Views: 3377

Re: How to use magma_*customspmv in the program?

Dear Hartwig, According to your first reply, I need to add awesome_spmv into magma_*customspmv.cpp. And set magma_*_matrix type as the Magma_SPMVFUNCTION. And I can use some routine like CG as I did before. By doing so, I can not use two different spmv methods at the same time. Is that correct? Than...
by mikemike10212003
Tue Nov 07, 2017 5:21 am
Forum: User discussion
Topic: How to use magma_*customspmv in the program?
Replies: 8
Views: 3377

Re: How to use magma_*customspmv in the program?

Dear Hartwig,

Sorry about the unclear declaration.
The wrapper of BLAS will use the magma_*customspmv when the storage_type is Magma_SPMVFUNCTION.
I also want to use the CG solver of MAGMA on the custom spmv function.
Thus, I think I can not just build a new function.

Thanks,
Mike
by mikemike10212003
Tue Nov 07, 2017 2:47 am
Forum: User discussion
Topic: How to use magma_*customspmv in the program?
Replies: 8
Views: 3377

How to use magma_*customspmv in the program?

Dear all, magma_*customspmv give me to use a custom function to calculate spmv. Do I need to edit the file "magma_*customspmv.cpp" to implement the function and recompile magma library? Is there any more convenient method to achieve it? Can I use two different custom spmv methods in one program? Tha...
by mikemike10212003
Sun Jan 15, 2017 12:04 pm
Forum: User discussion
Topic: Magma change storage_type error in GPU
Replies: 4
Views: 2331

Re: Magma change storage_type error in GPU

Dear Hartwig,
Thanks for your reply.
I changed the dT position to follow the error handling.
Thanks,
Mike
by mikemike10212003
Sun Jan 15, 2017 9:25 am
Forum: User discussion
Topic: Magma change storage_type error in GPU
Replies: 4
Views: 2331

Re: Magma change storage_type error in GPU

Dear all, magma-2.2.0 moves data to CPU, converts it and moves data to GPU based on Rowmajor. Thus, I guess I can change the part safety and it will not let another function get error. I use similar function in magma-2.1.0 and fix it with correct parameters. The main idea is using transpose but with...
by mikemike10212003
Tue Nov 08, 2016 4:25 am
Forum: User discussion
Topic: Magma change storage_type error in GPU
Replies: 4
Views: 2331

Magma change storage_type error in GPU

Dear all, I use magma_zmconvert function in GPU. Try dense to CSR and CSR to DENSE in GPU or CPU. In CPU, DENSE to CSR of CPU is based on RowMajor. CSR to DENSE of CPU is based on RowMajor. CSR to DENSE of GPU is based on ColMajor. I don't know how DENSE to CSR of GPU does, because it will return ju...
by mikemike10212003
Tue Oct 11, 2016 12:25 pm
Forum: User discussion
Topic: convert dense to csr and save it
Replies: 1
Views: 1015

Re: convert dense to csr and save it

Hi, I think I found the problem. It have some error in magma-2.1.0/sparse-iter/control/magam_zmio.cpp I change some variable, and the result it return is correct. //print in ColMajor of complex part fprintf( fp, "%d %d %d\n", int(B.num_cols), int(B.num_rows), int(B.nnz)); // TODO what's the differen...
by mikemike10212003
Mon Oct 10, 2016 5:43 am
Forum: User discussion
Topic: convert dense to csr and save it
Replies: 1
Views: 1015

convert dense to csr and save it

Hi, I create m*n dense matrix, convert it to csr and save it. However, it always returns segmentation fault. magma_init(); magma_int_t dev=0; magma_queue_t queue=NULL; magma_queue_create(dev, &queue); magma_z_matrix *A=new magma_z_matrix; int m=48, n=10; magmaDoubleComplex *val; val=new magmaDoubleC...