This law does not apply to filming the police. See the authoritative French government interpretation here:
http://www.montpellier-journal.fr/fichiers/circulairephotosp...
And see here where the French Constitutional Council struck down a law that would have criminalized filming with the intent to cause harassment of officers:
https://www.france24.com/en/live-news/20210520-french-court-...