Mace driver much slower than ASE client interface

37 views
Skip to first unread message

Kris Mu

unread,
Nov 17, 2025, 2:57:25 AMNov 17
to ipi-users
Hi developers, I was trying out the new internal MACE driver for i-pi, but it seems to be running slower for me than when I use the ASE client interface. Is that normal? A comment I saw suggested it should be about 10% faster, so I wanted to double-check if I might be doing something wrong. I've attached my input files. Thanks!
input.xml
mace_config.json
ase_driver.py
run.sh

Venkat Kapil

unread,
Nov 17, 2025, 3:28:10 AMNov 17
to ipi-users
Hi, thanks for raising this! Can you give some more specifics on "running slower for me than when I use the ASE client interface" so that we can fully understand what are the two setups that you are comparing. 

Kris Mu

unread,
Nov 17, 2025, 3:51:08 AMNov 17
to ipi-users

Thanks for the follow-up. Here are the specifics of the two setups I'm comparing:

ASE Interface: For this setup, you can refer to the ase_driver.py file I attached previously. It primarily uses ASE's SocketClient to communicate with i-pi.

Internal MACE Driver: For this setup, the command I used can be found in run.sh. The command is:

i-pi-py_driver -a 1 -u -m mace -o template=../../init/init.xyz,model=../../init/MACE-OFF24_medium.model,mace_kwargs=./mace_config.json,device=cuda

The mace_config.json file includes two additional MACE calculator parameters to ensure the settings are consistent with the ASE interface setup.

All other settings for both methods were identical.

Regarding the performance difference, the ASE interface ran at approximately 0.06 s/step, while the internal MACE driver ran at 0.09 s/step. Both simulations were run for several thousand steps.

Venkat Kapil

unread,
Nov 17, 2025, 4:03:26 AMNov 17
to ipi-users
Thanks! Does the absence of cueq in the "internal MACE Driver" explain it? 

Kris Mu

unread,
Nov 17, 2025, 4:07:30 AMNov 17
to ipi-users
I did add that parameter in mace_config.json. I also noticed that the GPU memory usage was the same for both simulations, which should indicate that cueq was enabled in both cases.

Venkat Kapil

unread,
Nov 17, 2025, 4:27:05 AMNov 17
to ipi-users
Hi, thanks for checking. It does look sus. Could I also ask you to check if this is a MACE issue or an ASE issue? It would be great if you could try some other potential implemented with ASE with the "internal driver" and the "ASE Client". 

Mariana Rossi

unread,
Nov 17, 2025, 7:42:44 AMNov 17
to ipi-users
Hi there, just checking one thing: are you using ffdirect? (https://docs.ipi-code.org/input-tags.html#ffdirect
I think not! Could you please try that and report whether you see the slow-down as well?  This is the fastest way to do it.

It still should not be slower than ASE with ffsocket, as that can only mean that there is a difference in the communication protocol with i-PI, which is unlikely as both are python and written quite similarly.

For that, it would be interesting to look at the log of MACE to see whether the model is really really the same in both of your runs. I know you said the memory is the same but still! Best to check directly.

Cheers,
Mariana
Reply all
Reply to author
Forward
0 new messages