CUDA tutorial: Difference between revisions

Jump to navigation Jump to search
Line 48: Line 48:
$ nvcc add.cu -o add
$ nvcc add.cu -o add
</source>
</source>
To run the program first create a Slurm job script called gpu_job.sh. See also [[Using GPUs with Slurm|using GPUs with Slurm]].
To run the program first create a Slurm job script called gpu_job.sh. Be sure to replace <code>def-someuser</code> with your specific account (see [[Running_jobs#Accounts_and_projects|accounts and projects]]). For various ways to schedule jobs with GPUs see [[Using GPUs with Slurm|using GPUs with Slurm]].  
{{File
{{File
   |name=gpu_job.sh
   |name=gpu_job.sh
Line 61: Line 61:
}}
}}


Submit your GPU job to the scheduler with this command.
Submit your GPU job to the scheduler with this command.  
<source lang="console">
<source lang="console">
$ sbatch gpu_job.sh
$ sbatch gpu_job.sh
cc_staff
1,486

edits

Navigation menu