999fd2807c746ab0c203f1ec20adcdd14be7da89,nn_dataflow/Partition.py,,get_ofmap_layout,#Any#Any#Any#Any#,308

Before Change


    // Eliminate the partitioning schemes which do not partition ofmaps (i.e.,
    // correspond to the same ofmap range). Merge them to BATP.
    for pae in range(pe.NUM):
        if pae not in [pe.OUTP, pe.OFMP, pe.BATP]:
            ofmap_pdims[pe.BATP] = [x * y for x, y in zip(ofmap_pdims[pe.BATP],
                                                          ofmap_pdims[pae])]
            ofmap_pdims[pae] = [1, 1]

    ofmap_part = PartitionScheme(order=ofmap_order, pdims=ofmap_pdims)
    assert all(od <= omrd for od, omrd in zip(ofmap_part.dim(), dim_omr)), \
            "Partition ofmap: ofmap partitioning {} is invalid within " \
            "memory region {}.".format(ofmap_part, str(output_mem_region))

After Change


            // Ofmap dimension > computation dimension. Extend.
            ext = od // pd
            // Apply the extension to the top level.
            top_pae = next(pae for pae in ofmap_order if pae in ofmap_paes)
            ofmap_pdims[top_pae][di] *= ext
        else:
            // Computation dimension >= ofmap dimension, shrink.
            // Go from bottom to top. Keep bottom (first) levels unchanged, and
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: stanford-mast/nn_dataflow
Commit Name: 999fd2807c746ab0c203f1ec20adcdd14be7da89
Time: 2017-07-13
Author: mgao12@stanford.edu
File Name: nn_dataflow/Partition.py
Class Name:
Method Name: get_ofmap_layout


Project Name: sentinel-hub/eo-learn
Commit Name: bf49375b5f60b5668f874a2f704fa718735e2ded
Time: 2018-08-08
Author: matej.aleksandrov@sinergise.com
File Name: features/eolearn/features/interpolation.py
Class Name: InterpolationTask
Method Name: execute


Project Name: sentinel-hub/eo-learn
Commit Name: 5bb91bfefafbf9cc643aa1a3c7c4d8fdfec46e56
Time: 2018-08-08
Author: matej.aleksandrov@sinergise.com
File Name: ml_tools/eolearn/ml_tools/postprocessing.py
Class Name: PostprocessingTask
Method Name: execute