~/talk

Testing stochastic AI models with Hypothesis

Talkat PyCon US 2021 · 2021-05-14..05-15· [testing, ai-assisted-development]
links:none on file
slides:none on file

Uses the Hypothesis library to generate and shrink failing examples, stores failing cases in a local database for repeatable random tests, and combines property-based testing with metamorphic relations to test medical-image feature extraction. Concrete checks include asserting features persist when adding extra connected components (generated via array strategies, composite draws and binary dilation) and asserting rotation invariance while mocking location-dependent calculations. Evidence: reproducible failures, automatic shrinking, numpy/pandas strategy support.

AI-written summary · about

  1. 0:00Intro
  2. 0:27About me
  3. 2:03Table of Content
  4. 3:16Example-based testing- example
  5. 3:44Example-based testing - issues
  6. 4:40Example-based testing - merge_sort
  7. 6:40Property: Commutativity
  8. 6:58Property: Invariant functions
  9. 7:15Property: The test oracle
  10. 7:55Property-based testing
  11. 8:34What are the properties in the example?
  12. 9:35Metamorphic Testing
  13. 10:59Metamorphic Relations
  14. 13:05Hypothesis Library
  15. 14:31Hypothesis basic strategies
  16. 15:53merge_sort test
  17. 16:11Define you own strategy
  18. 17:02Transforming data functions
  19. 17:33Debug hypothesis strategies
  20. 18:29Repeatable random testing
  21. 19:03Shrinking
  22. 21:10Additional Components
  23. 22:20Rotate the image
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.