I'm trying to download the networks models of a Neural Network project used to detect NSFW images. The packed models are available in the assets section of a release at this URL: https://github.com/notAI-tech/NudeNet/releases
I would like to create a DOCKERFILE which download these assets when built. I started using the ADD command, but the files didn't get downloaded entirely (only few kB over the 120 MB of some files). So, I tried in my Linux CLI using wget and curl... But nothing worked as expected. For example the command :
curl -OJL https://github.com/notAI-tech/NudeNet/releases/download/v0/classifier_model.onnx
Starts the download but only download an HTML file instead of the actual ONNX file... It seems Github is doing some kind of redirection and I don't know how I can handle it with curl/wget and finally with the ADD command of a DOCKERFILE ?
I did visit
https://github.com/notAI-tech/NudeNet/releases/download/v0/classifier_model.onnx
in my browser and I did get login page, so apparently it is not publicly available. That would explain why you did get small HTML file (file with login form).
Github is doing some kind of redirection and I don't know how I can
handle it with(...)wget
You need to provide authentication data, I do not know how it is exactly done in this case, but I suspect they might use one of popular methods: basic authentication (see wget options --http-user=user and --http-password=pass) or cookies based solution (see wget options --load-cookies file and --save-cookies file and --keep-session-cookies).
Mentonied options are described in wget man page, which you might access by click link or doing man wget in terminal.
Related
I'm trying to install PostgreSQL via Ansible on a Windows machine, meaning I'll need a URL. I know this shows me a download link, and I can usually right-click on the link and get the actual URL. Clocking on that line takes you to this page, and right-clicking on the start the download now link on that page doesn't give me a direct URL either, but a link to a javescript. I even looked a the HTML source in Brave browser Developer tools. I even found an example here, but the ftp url shown there doesn't have Windows installers. I also searched for "Postgres download URL" here, to no avail.
What the heck is the actual download URL, say for version 13?
On the page you linked to, if you click on the "Download" it takes you to this page](https://www.enterprisedb.com/postgresql-tutorial-resources-training?cid=437) which typically starts the download automatically.
However, there is a message
If your download does not begin automatically, start the download now
which is the direct link to the installer (in this case for 13.3)
I have a working Directus CMS environment and would like to include some custom pages in there as well. According to the documentation!, I "can build page modules for custom dashboards, reporting, point-of-sale systems, or anything else".
The CMS is downloaded from directus, installed in localhost and then moved with FTP to the server as my client doesn't have terminal access allowed.
I already tried the boilerplate from https://github.com/directus/extension-toolkit, created a vue page with it, ran npm to transpile it, but now I don't know where to put it. If I put it to public > extensions > custom > pages (I put here the whole created folder), it's not shown anywhere and I can't really find any tutorial or help on how to do it. Not even in the docs.
You have to copy only the dist subdirectory of the extension to your server.
Example:
directus-extensions create page orders
directus-extensions build
rsync ./dist/ root#example.com:/var/www/directus/public/extensions/custom/pages/orders/
You should now see your page extension listed in the sidebar when you log in to your Directus app (provided your user role is configured to display extensions in the sidebar).
Setting up a PowerShell script to auto-download applications with varying URLs.
I had a batch file script to download certain application to ensure my USB Toolkit was always updated. However I want to switch to powershell because I found it had the WGET command to download direct from a URL. What I was hoping, was to have the URL always get the latest version.
wget https://download.ccleaner.com/ccsetup556.exe -O ccleaner.exe
Note that the 556 in the URL is the variable I would like to always select the highest version.
They have two download pages, a direct link, and one that takes 2-5 seconds to download, however when I point wget to that page, it just downloads the HTML webpage.
I've been trying to figure out how to use the google closure library for d-pad navigation for my web app. I cannot for the life of me get closure to work. I'm following google's guide here https://developers.google.com/tv/web/lib/closure/gettingstarted
The guide asks to checkout from their SVN repo, but I'm just using the downloaded zip of the library from github. The guide asks to perform the following command
gtv-ui-lib/closure-library/closure/bin/build/depswriter.py \
--root_with_prefix="gtv-ui-lib/source ../../../../gtv-ui-lib/source" \
--output_file=tv-deps.js
to create a deps.js file. Can somebody explain to me how to execute this command? Is it supposed to be in a python command prompt or something else? When I copy and paste their exact html and javascript page code and use the premade deps.js file for the guide, my page doesn't function with keyboard navigation, so I'm assuming the deps.js file is my problem because everything else is exactly from the guide.
You will need to have python installed on your development machine and make sure that it is added to your path environment. The closure depswriter can be executed by using python from the command line (if you are using *nix then you can just invoke the file from the cli). Try:
python WHERE-YOU-UNZIPPED-THE-ZIP-PATH/gtv-ui-lib/closure-library/closure/bin/build/depswriter.py \
--root_with_prefix="gtv-ui-lib/source ../../../../gtv-ui-lib/source" \
--output_file=tv-deps.js
I would also recommend checking out the source from the SVN repo and not using the github zip file. The SVN repo is the most upto date and the github is a mirror that can sometimes fall behind. To ensure you have the latest version of the code do install the SVN tools and checkout from the specified repo.
how download site for viewing offline without specific folder
for example i want download the site without http://site.com/forum/ sub-directory
wget --help
might lead you to
-nH, --no-host-directories don't create host directories.
I'd try that first, but I'm not sure whether it will do what you want.