-
Notifications
You must be signed in to change notification settings - Fork 49
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
dlc-live-test
works on Linux only
#51
Comments
HI @eggplants thanks! But I can confirm out code is used/tested on Windows10 (even in my own lab :). So curious more about what caused this error - can you elaborate on your setup/system? |
|
I suppose this depends on the terminal you use in Windows (probably you use gitbash, @MMathisLab). But I guess @eggplants's solution applies more broadly. |
The most cross-platform thing to do would probably be to use python stdlib (urllib and tarfile) instead of relying on system libs (which, as you note, may or not be present on a given machine). I actually fixed this in #60 along with a few other quirks of the My approach was to do it like this (full code in PR): # download dog test video from github:
print(f"Downloading Video to {video_file}")
url_link = "https://github.com/DeepLabCut/DeepLabCut-live/blob/master/check_install/dog_clip.avi?raw=True"
urllib.request.urlretrieve(url_link, video_file, reporthook=urllib_pbar)
# download exported dog model from DeepLabCut Model Zoo
if Path(model_tarball).exists():
print('Tarball already downloaded, using cached version')
else:
print("Downloading full_dog model from the DeepLabCut Model Zoo...")
model_url = "http://deeplabcut.rowland.harvard.edu/models/DLC_Dog_resnet_50_iteration-0_shuffle-0.tar.gz"
urllib.request.urlretrieve(model_url, str(model_tarball), reporthook=urllib_pbar)
print('Untarring compressed model')
model_file = tarfile.open(str(model_tarball))
model_file.extractall(str(model_dir.parent))
model_file.close() Seems like this was closed, but it does seem like a compatibility issue since I imaging there will be lots of folks using default windows command prompt |
On windows Powershell,
tar.exe
raises errortar.exe: Error opening archive: Failed to open '\\.\tape0'
.This kind of code is compatibile:
The text was updated successfully, but these errors were encountered: