GithubHelp home page GithubHelp logo

sanger-machine-learning-workshop's People

Contributors

mrahtz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

sanger-machine-learning-workshop's Issues

Error while running learn.py file

Traceback (most recent call last):
File "learn.py", line 68, in
main()
File "learn.py", line 55, in main
reconstruction = learn_utils.reconstruct(data, window, clusterer)
File "/Users/hotify/Downloads/thermometr-master/models/learn_utils.py", line 63, in reconstruct
nearest_match_idx = clusterer.predict(segment)[0]
File "/usr/local/lib/python2.7/site-packages/sklearn/cluster/k_means_.py", line 981, in predict
X = self.check_test_data(X)
File "/usr/local/lib/python2.7/site-packages/sklearn/cluster/k_means
.py", line 865, in _check_test_data
X = check_array(X, accept_sparse='csr', dtype=FLOAT_DTYPES)
File "/usr/local/lib/python2.7/site-packages/sklearn/utils/validation.py", line 410, in check_array
"if it contains a single sample.".format(array))
ValueError: Expected 2D array, got 1D array instead:
array=[ -0.00000000e+00 -4.09401175e-02 -2.02605471e-01 -1.79236559e-01
-3.11033081e-01 -7.06553985e-01 -6.52694747e-01 -1.69714444e+00
-2.62662292e+00 -5.00261013e+00 -5.04137953e+00 -8.86658290e+00
-7.03503249e+00 -1.03089064e+01 -1.07477659e+01 -8.97691196e+00
9.97434662e-01 5.86241777e+00 1.12460797e+01 9.67316967e+00
1.93452718e+01 1.22433503e+01 6.87858893e+00 -1.05064917e+00
-4.24286111e-01 -5.87425272e+00 -4.47484190e+00 -3.42136389e+00
-1.70274731e+00 -9.31985166e-01 -1.94465558e-01 -3.59942348e-31].
Reshape your data either using array.reshape(-1, 1) if your data has a single feature or array.reshape(1, -1) if it contains a single sample.

ekG

ekg

can you provide the solution for this ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.