Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-22707

Optimize CrossValidator memory occupation by models in fitting

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.2.0
    • Fix Version/s: 2.3.0
    • Component/s: ML
    • Labels:
      None
    • Target Version/s:

      Description

      Via some test I found CrossValidator still exists memory issue, it will still occupy `O(n*sizeof(model))` for holding models when fitting, if well optimized, it should be `O(parallelism*sizeof(model))`

      This is because modelFutures will hold the reference to model object after future is complete (we can use `future.value.get.get` to fetch it), and the `Future.sequence` and the `modelFutures` array holds references to each model future. So all model object are keep referenced. So it will still occupy `O(n*sizeof(model))` memory.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                weichenxu123 Weichen Xu
                Reporter:
                weichenxu123 Weichen Xu
                Shepherd:
                Joseph K. Bradley
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: