How to configure extra options on submit command

16 views
Skip to first unread message

daniel....@gmail.com

unread,
Jul 15, 2021, 11:07:13 AM7/15/21
to aiidausers
Hi Everyone,

I want to change the way aiida submits my jobs. Original it was:

$sbatch _aiidasubmit.sh

Now I want something like

$sbatch -A mr23 -C mc _aiidasubmit.sh

Thanks! 

Daniel 

Giovanni Pizzi

unread,
Jul 15, 2021, 12:32:24 PM7/15/21
to AiiDA users mailing list
Hi Daniel.
You can specify those options directly in the file, rather than in the command line.

For the account (-A), this already exists as an option in AiiDA, you can do something like this when you submit:

[...]
            'metadata': {
                'options': {
                    'resources': {"num_machines": 1},
                    'max_wallclock_seconds': max_walltime,
                    'account': 'mr23'
                }
[...]

For the -C option, I think we don't have an option yet, but you can use the custom_scheduler_commands, adding one more key to the `options` dictionary above:
'custom_scheduler_commands': '#SBATCH -C mc'
(the second string is the syntax of sbatch to specify the options in the file rather than in the command line - note that I didn't check it).

You can see all options here:

Another way to achieve the goal is to create a computer `daint-mc` for the multicore partition and, in the prepend-text of the computer, add `#SBATCH -C mc`.
[You can create a second computer `daint-gpu` for the GPU partition, if you have access to it (in any case, you'll have to use different codes, so having two computers is not a real issue).]

Best,
Giovanni


--
AiiDA is supported by the NCCR MARVEL (http://nccr-marvel.ch/), funded by the Swiss National Science Foundation, and by the European H2020 MaX Centre of Excellence (http://www.max-centre.eu/).
 
Before posting your first question, please see the posting guidelines at http://www.aiida.net/?page_id=356 .
---
You received this message because you are subscribed to the Google Groups "aiidausers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to aiidausers+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/aiidausers/a5a24221-3a2d-4a2a-b1a4-a32c2d8a89a9n%40googlegroups.com.

daniel....@gmail.com

unread,
Jul 16, 2021, 7:31:09 AM7/16/21
to aiidausers
Thanks this worked well for me. I ended up going with creating a new computer and prepending "#SBATCH -C mc'" as a command 


Daniel 

Reply all
Reply to author
Forward
0 new messages