I wrote two separate functions. One generates the compressed form directly, without relying on an existing X; The other generates the compressed form from an existing X.
I hope this covers what they're asking for, as at least one of these approaches s...
just started the project and was wondering if anyone understands the wording for task 2
Write separate code for generating the B and C matrices given a matrix X. You can generate the matrix X inside this code.
is this suggesting that i generate B and ...
In mid test, Q12
it use private(k) so k is not initialized.
That means it can be any value.
So all the answers are possible.
If I misunderstand something pls tell me.
I think in lecture, it only mentions static, dynamic, guided, runtime.
With runtime you can set the chunk size in script.
But I am also confused whether I should make runtime as a indepedent strategy.
OpenMP offers five scheduling schemes for the pragma omp parallel for directive.
However, out of these, only static , dynamic , and guided are the real deal when it comes to scheduling.
The other two, runtime and auto , aren t true scheduli...
For me I've currently been using
SBATCH --nodes 1
SBATCH --ntasks 1
SBATCH --cpus-per-task I change this for the thread count
SBATCH --partition work
SBATCH --account courses0101
SBATCH --mem 220G (definitely overkill, but works)
SBATCH --time 01 ...
Hi Benjamin,
At this moment, I just use command to test my program and set the total thread number to 1. I will do the batch bash program later to add the nodes or cores for getting more test results.
Thanks,
Joey
What does your sbatch script contain? My Setonix jobs sit in a queue for a full day before executing, and OpenMP has been doing nothing for me. What values do you have for --nodes and --ntasks, and are you using the --cpus-per-task directive?
Likewise - 10000 took around a second, and for me doubling the size led to a 10x time increase, so mine will take somewhere around 3 hours
Feels quite long however, it will make repeated tests and comparisons difficult
A minimal test case to show the performance difference.
openmp 101.c
c
include inttypes.h
include limits.h
include omp.h
include stdint.h
include stdio.h
include stdlib.h
int main()
printf("omp get max threads() u n", omp get max ...
Moreover I have never tried to use sbatch before because I thought running a program with srun should have identical or at least similar performance.
For example, if I were you I would run openmp 101-b.sh as
bash
cc -fopenmp -o openmp 101 . op...
First I would like to point out that your code may have undefined behavior. int i and long loops have different data type, and loops have value equal to 10000000000 which is greater than INT MAX, so the loop should never finish. But since the beh...
Thats not far off the times I'm having as well, I'm under the assumption it is supposed to take quite a long time. Though I could also not be using the optimal algorithm but regardless I'm assuming it will take a long time.
My sparse multiplication algorithm used about 1 sec for size 10000 but after that the time growth in a exponential speed and very likely would take about an hour for size 100000. I guessing I might not using the optimal algorithm, is there any hint?
Hello Professor,
as stated in the project "Your code should write the final results for the B and C
matrices in two separate files named FileB and FileC"
Can you please verify that
For matrix multiplication X Y Z, we will be saving the all the matrices...
Additionally, measuring the longest-running thread won't accurately reflect total time consumed if multiple threads are time-sharing the same CPUs, especially when the number of threads exceeds the number of available CPUs. This is why I believe wtim...