human
Python: Sum values in a dictionary based on condition
assistant
Here is some code to sum values greater than 0 in dictionary `d`

sum(v for v in list(d.values()) if v > 0)

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.