Asset selection for a portfolio


Hi .. I am looking to rebalance a portfolio based on a parent portfolio (will be rebalancing periodically based on same approach). Let's say the parent portfolio has M assets. For each of these M assets I have their weights available (W), their dividend yield (D) and volatility (V). These M assets will have a certain geographical and sectorical allocation.

I want to rebalance an 'EQUI-WTD' subset of 'm' assets (m<M) so as to

Max (D-V)

Subject to: active geographical allocation and active sectorical allocation < 5%

I guess it's a pretty straightforward problem if m=M. However, in this case it looks like I might need a combinatorial optimisation. Any suggestions ? I am doing this in Python. Not sure of any library that can help with this.