Effect of strain localization on frictional behavior of sheared granular materials