🔥 Burn Fat Fast. Discover How! 💪

Paranoid Scientist is a #python module for verifying scientifi | Opensource Findings

Paranoid Scientist is a #python module for verifying scientific software.

It provides:
- Runtime verification of entry and exit conditions written in pure Python, including hyperproperties.
- Conditions specified using pure Python refinement types, i.e. types are defined by predicates.
- Automated unit testing of individual functions.

It is inspired by contract-oriented programming, type classes, static type checking, and fuzz testing.

Paranoid Scientist is a tool to make sure scientific code is correct. Verification is extremely important for scientific software because, unlike most software, we don’t know what the output will be until we run the program. In fact, the program is written in order to examine the output. However, we have no robust way of knowing whether the output is due to a software bug. For example, code performing a complex statistical test could normalize the wrong column, an error which would likely go undetected.

Paranoid Scientist attempts to remedy this situation by providing some key tools from the software verification community to the scientific community. Traditional program verification asks the question, “If I run my code, will it run correctly?” In practice, this is time consuming and requires highly specialized training. For scientific programming, it is acceptable to instead ask, “If I already ran my code, did it run correctly?” In other words, it is not as important to know before executing the program whether it will run correctly. Paranoid Scientist is already in use in scientific software.

https://github.com/mwshinn/paranoidscientist