Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Access Denied Tensorflow Error? #50

Closed
Caleb-J773 opened this issue Jun 12, 2017 · 25 comments
Closed

Access Denied Tensorflow Error? #50

Caleb-J773 opened this issue Jun 12, 2017 · 25 comments

Comments

@Caleb-J773
Copy link

Could not open C:\Users\User1\Desktop\aidrivers: Unknown: NewRandomAccessFile failed to Create/Open: C:\Users\User1\Desktop\aidrivers : Access is denied. ; Input/output error

Why is this happening? All i did was update to the newest pygta5? I tried putting it into another folder but that doesn't seem to fix that error.

@J-XianSheng
Copy link

set
MODEL_NAME = 'anything'

LOAD_MODEL = False

@Caleb-J773
Copy link
Author

Okay that fixed it kinda but now there's a new error. It can't actually find any npy files when they are there.

[Errno 2] No such file or directory: 'J:/phase10-random-padded/training_data-1778.npy' [Errno 2] No such file or directory: 'J:/phase10-random-padded/training_data-1276.npy' I tried changing up the directory it was listing to my pc but it still can't find any training files.

@mantoone
Copy link

Where did you save the files? It works fine for me, but I did need to change the paths in the scripts.

@Caleb-J773
Copy link
Author

I made a new folder and saved it to my desktop
C:\Users\User1\Desktop\drivers

@mantoone
Copy link

If you want to save the recorded data there change the line https://github.com/Sentdex/pygta5/blob/master/1.%20collect_data.py#L101
file_name = 'X:/pygta5/phase7-larger-color/training_data-{}.npy'.format(starting_value)
to
file_name = 'C:/Users/User1/Desktop/drivers/training_data-{}.npy'.format(starting_value)

@Caleb-J773
Copy link
Author

Okay but it's also doing the same errors to the other files, like training data and testing data. but im sure testing data is just acting like that cause well training data file isn't working, i'll try your step

@Caleb-J773
Copy link
Author

Caleb-J773 commented Jun 14, 2017

Alright this isn't working Training data is just refusing to work, There must be something wrong with the current code.
[Errno 2] No such file or directory: 'C:/Users/User1/Desktop/drivers/training_data-1127.npy'
[Errno 2] No such file or directory: 'C:/Users/User1/Desktop/drivers/training_data-172.npy'
[Errno 2] No such file or directory: 'C:/Users/User1/Desktop/drivers/training_data-1575.npy'
[Errno 2] No such file or directory: 'C:/Users/User1/Desktop/drivers/training_data-249.npy'
[Errno 2] No such file or directory: 'C:/Users/User1/Desktop/drivers/training_data-874.npy'
[Errno 2] No such file or directory: 'C:/Users/User1/Desktop/drivers/training_data-119.npy'
training_data-2.npy 500

(It skips -1 )

It's not even training anymore.

@mantoone
Copy link

Did you check that the folder contains those files? I needed to adjust the FILE_I_END variable. Take a look at https://github.com/Sentdex/pygta5/blob/master/Versions/v0.03/2.%20train_model.py#L11

If you have data until training_data-100.npy, change it to FILE_I_END = 100

@Caleb-J773
Copy link
Author

Caleb-J773 commented Jun 14, 2017

The folder has training data 1 and 2 , that's it
just for the start

@mantoone
Copy link

Try FILE_I_END = 2

@Caleb-J773
Copy link
Author

Caleb-J773 commented Jun 14, 2017

Traceback (most recent call last): File "C:\Users\User1\Desktop\drivers\test_model.py", line 245, in <module> main() File "C:\Users\User1\Desktop\drivers\test_model.py", line 148, in main delta_count_last = motion_detection(t_minus, t_now, t_plus) File "C:\Users\User1\Desktop\drivers\motion.py", line 46, in motion_detection dst = cv2.addWeighted(screen,1.0, delta_view,0.6,0) NameError: name 'screen' is not defined
Test_model is erroring out now. I have everything installed and just verified, Python has all the requirements satisfied

Also doing what you told me above allowed me to train finally, but running into this problem ^^

@mantoone
Copy link

Great!

There's a bug with the motion script. You need to add screen as a parameter to the function:
So change:
def motion_detection(t_minus, t_now, t_plus):
To:
def motion_detection(t_minus, t_now, t_plus, screen):

And in the test_model script add screen to the function call:
https://github.com/Sentdex/pygta5/blob/master/3.%20test_model.py#L148

@Caleb-J773
Copy link
Author

Caleb-J773 commented Jun 15, 2017

Okay now it's giving this error
Traceback (most recent call last):
File "test_model.py", line 245, in
main()
File "test_model.py", line 190, in main
motion_log.append(delta_count)
NameError: name 'delta_count' is not defined

@mantoone
Copy link

mantoone commented Jun 15, 2017

I suppose delta_count should be delta_count_last on the line:
https://github.com/Sentdex/pygta5/blob/master/3.%20test_model.py#L190

@Caleb-J773
Copy link
Author

Okay well that somehow worked but it's still not training. I waited 1 hour for it to train and it "trained" yet the file never updated. and just started to repeat.

@mantoone
Copy link

What was the output from the "2. train_model.py" script? Did you add the same MODEL_NAME to the test_model script?

@Caleb-J773
Copy link
Author

I added the same model name, There's no error other then MODEL SAVED. then it just repeats the same training data over and over

@mantoone
Copy link

The model is saved every 10th epoch. It should finish automatically when it's done. By default after 30 epochs (30 passes over the data).

@DanMossa
Copy link

DanMossa commented Jul 5, 2017

Hey @mantoone . I'm also having the same error. I changed

MODEL_NAME = 'anything'

LOAD_MODEL = False

And I only have up to
training_data-200.npy

So I set FILE_I_END = 200

And now I get

training/training_data-37.npy
training_data-37.npy 500
---------------------------------
Run id: anything
Log directory: log/
---------------------------------
Training samples: 450
Validation samples: 50
--
Cannot feed value of shape (64, 17) for Tensor 'targets/Y:0', which has shape '(?, 9)'
training/training_data-69.npy
training_data-69.npy 500
---------------------------------
Run id: anything
Log directory: log/
---------------------------------
Training samples: 450
Validation samples: 50
--
Cannot feed value of shape (64, 17) for Tensor 'targets/Y:0', which has shape '(?, 9)'
training/training_data-190.npy
training_data-190.npy 500
---------------------------------
Run id: anything
Log directory: log/
---------------------------------
Training samples: 450
Validation samples: 50
--
Cannot feed value of shape (64, 17) for Tensor 'targets/Y:0', which has shape '(?, 9)'
training/training_data-112.npy
training_data-112.npy 500
---------------------------------
Run id: anything
Log directory: log/
---------------------------------
Training samples: 450
Validation samples: 50
--
Cannot feed value of shape (64, 17) for Tensor 'targets/Y:0', which has shape '(?, 9)'
training/training_data-157.npy
training_data-157.npy 500
---------------------------------
Run id: anything
Log directory: log/
---------------------------------
Training samples: 450
Validation samples: 50
--
Cannot feed value of shape (64, 17) for Tensor 'targets/Y:0', which has shape '(?, 9)'
training/training_data-58.npy
training_data-58.npy 500
---------------------------------
Run id: anything
Log directory: log/
---------------------------------
Training samples: 450
Validation samples: 50
--
Cannot feed value of shape (64, 17) for Tensor 'targets/Y:0', which has shape '(?, 9)'
training/training_data-104.npy
training_data-104.npy 500

Over and over until I stop it

@mantoone
Copy link

mantoone commented Jul 5, 2017 via email

@DanMossa
Copy link

DanMossa commented Jul 5, 2017

@mantooneoops I did change it.

Thanks mate

@mantoone
Copy link

mantoone commented Jul 6, 2017 via email

@frossaren
Copy link

@mantoone It would be nice if you did a pull request on your fix for screen not defined in motion. I think many people have the same problem

@mantoone
Copy link

@frossaren There it is now: #64

@frossaren
Copy link

frossaren commented Aug 12, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants