ColasGael / Machine-Learning-for-Solar-Energy-Prediction

Predict the Power Production of a solar panel farm from Weather Measurements using Machine Learning
MIT License
235 stars 112 forks source link

.fit attribute #3

Closed sethubhargavmeruga closed 5 years ago

sethubhargavmeruga commented 5 years ago

'function' object has no attribute 'fit' . Please resolve this issue.

adelekuzmiakova commented 5 years ago

Hi sethubhargavmeruga,

Many thanks for raising this issue! Can you please tell me which code you're running? That would help me identify what the problem might be. Thanks again :-) -Adele

sethubhargavmeruga commented 5 years ago

I'm running the recurrent neural network file , there is an issue with fit attribute. the following is the compiler result. I have installed numpy yet this is the error. [Running] python -u "d:\Btech Project\Machine-Learning-for-Solar-Energy-Prediction-master\Recurrent Neural Network\rnn.py" Traceback (most recent call last): File "d:\Btech Project\Machine-Learning-for-Solar-Energy-Prediction-master\Recurrent Neural Network\rnn.py", line 1, in import numpy as np ModuleNotFoundError: No module named 'numpy'

[Done] exited with code=1 in 0.396 seconds

sethubhargavmeruga commented 5 years ago

There is also a problem with the weighted linear regression file. the following is the error : Error using datetime (line 556) Numeric input data must be a matrix with three or six columns, or else three or six separate numeric arrays. You can also create datetimes from a single numeric array using the 'ConvertFrom' parameter.

Error in weighted_linear_regression (line 18) timeline = datetime(timeline,'Format','dd-MM-yyyy'); % the dates of every example of the test set

sethubhargavmeruga commented 5 years ago

Please help me and kindly guide me through the project as this is really important for my credits. thanks in advance. If willing to email : sbm11@iitbbs.ac.in

adelekuzmiakova commented 5 years ago

Cool - what python version are you running? Thanks :)

sethubhargavmeruga commented 5 years ago

I'm using the 3.8 version .

ColasGael commented 5 years ago

For the weighted linear regression: The datetime parsing works on my machine (Matlab 8.6) with our weather_test_timeline.csv

But it doesn't really matter if it does not work on your machine: this parsing is only use for plotting on a time axis. You can create your own parsing or your own plots, no need to use ours. You can remove the following lines and the computations should still as a charm.

https://github.com/ColasGael/Machine-Learning-for-Solar-Energy-Prediction/blob/master/Weighted%20Linear%20Regression/weighted_linear_regression.m#L16-L18 https://github.com/ColasGael/Machine-Learning-for-Solar-Energy-Prediction/blob/master/Weighted%20Linear%20Regression/weighted_linear_regression.m#L96-L128 https://github.com/ColasGael/Machine-Learning-for-Solar-Energy-Prediction/blob/master/Weighted%20Linear%20Regression/weighted_linear_regression.m#L135-L163