Yes. I wrote a paper on it a long time ago. Even on the lowest carbon footprint, vegan, diet and even with coal power and even accounting for production and lifetime costs, electric bicycles have a smaller footprint than walking or traditional bicycles. Probably even more so now as the numbers I were using were 20 years ago when e-bikes were not fully enjoying economies of scale.

E-bikes are really power efficient, and food production is very inefficient. Your average American commute probably uses less power per day than a refrigerator.

That said, it’s not really meaningful when comparing to the carbon footprint of driving. Diet and e-bike vs bike just really does not matter compared to the choice of driving an ICE or not driving an ICE. It’s more of just a neat fact.