Mainly dev Parameter Sweep
- moved parameter initialization to function
- deal with Mongo InvalidDocument (too large)