Shared file-system is a file?

link to doc
According to the doc page, this is how you initialize a shared file-system.

dist.init_process_group(backend, init_method='file:///mnt/nfs/sharedfile',
                        world_size=4, rank=args.rank)

And in the warning box above the code in the doc page, it says this code creates a file. Does this mean that I can’t use it as a directory?

No, the path has to be a file. If all your processes gracefully terminate the file will be removed. If one of your processes crashes, it may not be deleted and you’ll have to delete it yourself.