Unhandled Promise Rejection

I am getting an error in numOfFeatures line. It says unhandled Promise Rejection. Could please help me out ! Kindly find the files attached below.

[code removed - moderator]

@balaji.ambresh Can you please check this out !!

If the file wdbc-train.csv is not in the location /data/, this promise rejection will happen.
Please fix the location to the training data, keeping in mind how the server views root location.

The file wdbc-train.csv is in the location /data/. I have moved the html file to that folder and ran the code. It showing error like this …

Failed to load resource: the server responded with a status of 404 ()

404 means the resource is not found.

Please do the following:

  1. Create a directory and drop the csvs and html files inside it. Let’s call this directory as c1w1.
  2. cd c1w1
  3. python -m http.server
  4. Fix all file references with respect to current directory.
  5. Open localhost url on browser to debug your implementation. It’ll be something like http://localhost:8000/your_assignment_file.html

How to do this json file ?

Once the model is done training, the model.save('downloads://my_model') should store 2 files. You have to zip them.

After the execution of code, only my_model.weights.bin is downloaded. The first file is not downloading.

What browser are you using?

I am using Safari browser

Please use google chrome. When the browser asks for downloading multiple files, allow it.

The Webserver URLs says undefined ! What to do ?

It seems like you are using a chrome extension. I haven’t used this. Did the python setup I gave you work?

I have figured out other way for that. But when i do this Python server i get server 404 error again.

I have tried the above steps, I still get the error. Please look into it.

Please click my name and message your assignment.

Update
Based on the files you sent me less than an hour ago, the file is named as data1.js. In script.js, you are trying to import data.js which doesn’t exist. Please change your script or rename the file to match the import statement.

1 Like