Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(4)  |  Call(2)  |  Derive(0)  |  Import(2)

src/n/i/nilmtk-HEAD/nilmtk/disaggregate/co_1d.py   nilmtk(Download)
from nilmtk.utils import find_nearest
from nilmtk.utils import find_nearest_vectorized
from nilmtk.disaggregate.disaggregator import Disaggregator
from nilmtk.sensors.electricity import Measurement, ApplianceName
 
        while start + min(nvalues, MAX_VALUES_TO_CONSIDER) - 1 < nvalues:
            [states_temp, residual_power_temp] = find_nearest_vectorized(
                sum_combination, test_mains.values[start:start + MAX_VALUES_TO_CONSIDER])
            states = np.append(states, states_temp)
            residual_power = np.append(residual_power, residual_power_temp)
            start += MAX_VALUES_TO_CONSIDER
 
        # If some values are still left
        [states_temp, residual_power_temp] = find_nearest_vectorized(
            sum_combination, test_mains.values[start:nvalues])

src/n/i/nilmtk-HEAD/nilmtk/disaggregate/fhmm_exact.py   nilmtk(Download)
from nilmtk.utils import find_nearest
from nilmtk.utils import find_nearest_vectorized
from nilmtk.disaggregate.disaggregator import Disaggregator
from nilmtk.sensors.electricity import Measurement
from nilmtk.preprocessing.electricity.single import contiguous_blocks