Skip to content

CLI tool to easily expand a list of hostnames (which include brackets) and write to a hosttile

Notifications You must be signed in to change notification settings

zanussbaum/nodelist-inflator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nodelist-Inflator

This is a simple CLI tool to extract individual nodes (hostnames) from a nodelist and write them to a file to be used by DeepSpeed.

For example, if you have a nodelist containing the following:

ip-xxxxxx,ip-yyyyyy,ip-aaaaa-[b-c,f]

It will write the following to the file hostname

ip-xxxxxx slots=8
ip-yyyyyy slots=8
ip-aaaaab slots=8
ip-aaaaac slots=8
ip-aaaaaf slots=8

Usage

Write a hostfile on the fly (useful for DeepSpeed integreations)

foo@bar:~$ nodelist_inflate --nodelist=ip-xxxxxx,ip-yyyyyy,ip-aaaaa-[b-c,f] --write

Get the rank of the current host

foo@bar:~$ nodelist_inflate --nodelist=ip-xxxxxx,ip-yyyyyy,ip-aaaaa-[b-c,f] --hostname=ip-xxxxxx
0 # the index of the hostname in the nodelist

About

CLI tool to easily expand a list of hostnames (which include brackets) and write to a hosttile

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages