I followed this one: How To Install TensorFlow on M1 Mac (The Easy Way) | by Prabhat Kumar Sahu | Medium to install tf 2.7.