add command count arg to init_pipeline