Welcome to the forum.
Either of these formulae should do what you want:
Formula:
=SUM(IF(FREQUENCY(IF((A2:A7=1)*(B2:B7<>"HUMA"),IF(B2:B7<>"",MATCH(B2:B7,B2:B7,0))),ROW(B2:B7)-ROW(B2)+1),1))
=SUM(--(FREQUENCY(IF((A2:A7=1)*(B2:B7<>"HUMA"), COUNTIF(B2:B7, "<"&B2:B7), ""), COUNTIF(B2:B7, "<"&B2:B7))>0))
Important: these are array formulae so need to be entered using Ctrl-Shift-Enter not just Enter. You will know the array is active when you see curly brackets { } appear around your formula - don't try to enter them yourself. If you do not Ctrl-Shift-Enter you will get an error or a clearly incorrect result. If that happens, just click into the formula bar and try again.
Change the ranges to match your actual data, of course 
Hope that helps.
Bookmarks