Precision crop safety relies on automated systems for detecting and classifying plants. This work proposes the detection and classification of nine species of plants of the PlantVillage dataset using the proposed developed compact convolutional neural networks and AlexNet with transfer learning. The models are trained using plant leaf data with different data augmentations. The data augmentation shows a significant improvement in classification accuracy. The proposed models are also used for the classification of 32 classes of the Flavia dataset. The proposed developed N1 model has a classification accuracy of 99.45%, N2 model has a classification accuracy of 99.65%, N3 model has a classification accuracy of 99.55%, and AlexNet has a classification accuracy of 99.73% for the PlantVillage dataset. In comparison to AlexNet, the proposed models are compact and need less training time. The proposed N1 model takes 34.58%, the proposed N2 model takes 18.25%, and the N3 model takes 20.23% less training time than AlexNet. The N1 model and N3 models are size 14.8 MB making it 92.67% compact, and the N2 model is 29.7 MB which makes it 85.29% compact as compared to AlexNet. The proposed models are giving good accuracy in classifying plant leaf, as well as diseases in tomato plant leaves.