Add another class to the div you want to count
<div class="Main">
<div class="pipe count_this">
<div class="mine"></div>
<div class="mine"></div>
<div class="mine"></div>
</div>
<div class="pipe">
<div class="mine"></div>
<div class="mine"></div>
</div>
</div>
Then use $(.count_this.mine).length