Posts

Showing posts from 2023

Useful Python Video Scripts

Taken from a LinkedIn post. Useful Python Scripts:  https://videonerd.website/useful-python-scripts/ Python Scripts for Computer Vision:  https://videonerd.website/python-scripts-for-computer-vision/ Python Scripts to Analyze and Process Transport Streams: https://videonerd.website/python-scripts-to-analyze-and-process-transport-streams/

Git Hell

 Git might just be the worst piece of software ever written.  I'm keeping notes for myself here. - git checkout and git switch - why git sucks so badly

10 Basic Design Patterns

Image
 

How To Use llvm-cov

How To Use llvm-cov Instrumenting your code for llvm-cov See also: https://llvm.org/docs/CommandGuide/llvm-cov.html - Build the code with code coverage turned on: Compile with the -fprofile-arcs and -ftest-coverage options to add the instrumentation. - Run your program, this creates a default.profraw file: % ./program - Run llvm-profdata to create a default.profdata file: % llvm-profdata merge -sparse default.profraw -o default.profdata - Run llvm-cov show for the module you care about: % llvm-cov show -output-dir=output --format=html -instr-profile=./default.profdata ./program /full/path/to/source/module - Now in the output directory you will find an index.txt file, the coverage numbers are in there. - If you want to get coverage for a directory like player or media, you need to specify the .cpp and .hpp files: % llvm-cov show -use-color=0 -output-dir=output -instr-profile=./default.profdata ./program /full/paht/to/source/module/*.[ch]pp