The invention discloses a video
anomaly detection method and
system based on a
global local feature double-flow network. The method comprises the following steps: 1.1, loading an original video training and
test data set; 1.2, dividing a video
frame sequence and constructing a corresponding
optical flow frame sequence; 2.1, constructing a video
anomaly detection model based on global and local
feature fusion; 2.2, the model takes a video
frame sequence and an
optical flow frame sequence as input of an appearance
branch encoder and an input of a motion
branch encoder respectively, and appearance feature codes and motion feature codes are extracted respectively; 2.3, restoring the image by the appearance and motion decoder, and generating a prediction frame image matched with the corresponding mode; 2.4, calculating an appearance and motion joint
loss function, performing back propagation, and optimizing a codec of a
branch; 3.1, dividing the test video into a video frame sequence and an
optical flow frame sequence; 3.2, inputting into a trained model to generate a prediction frame image at the next moment; 3.3, calculating abnormal scores of the appearance
stream and the motion
stream of each test video frame; and 3.4, when the abnormal
score exceeds a threshold value, judging the current frame as an abnormal frame.