Python Forum
installing any package= impossible headache
Thread Rating:
  • 2 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
installing any package= impossible headache
#1
So I want to make animation move to the beat of music, viewable on youtube. I figure I need to mess with mp4 etc stuff so I guess I need pymovie. I downloaded the source which 7zipped to a folder "moviepy-0.2.3.2". I paste this folder into c:\mypy where all my horse shit programs are. import moviepy doesn't work of course. So I notice that folder has a sub folder "moviepy" inside it. I copy that out of it and place that in c:\mypy. Pasted in some random code example I found, says "no m odule named tqdm". So maybe my copy pasting the folder didn't install it "correctly". So I look how do you install moviepy. You have to open the command prompt, the thing that never works, ever. This page shows 3 possible lines starting with (sudo).
https://zulko.github.io/moviepy/install.html
Just finding the stupid command prompt is a pain cuz I never use it, figuring out how to type cd etc to change directory, ugh. Anyway, I type each stupid line in c:\Users\user, I mean if it even matters which folder you're in when you type this crap, I don't know. It says "pip was unexpected at this time" and "python was unexpected at this time". So I navigate to c:\mypy\moviepy-0.2.3.2 and try, all give same useless errors. I try c:\mypy\moviepy, same useless errors. So in conclusion, like always, anyone else's package/code is totally unusable. I managed to successfully install pygame one time at least. At least this doesn't use the total joke "wheel files" which when I last tried, you seriously needed to install something to open a wheel file and that thing to install WAS a wheel file, so you need it to open itself, some sort of whimsical joke played on all who try to use it. So how the hell do you use this shit, is it even possible? Is it supposed to be easy, or are the creators of these things playing jokes on us. I mean, I like programming, you know, programming, the part you can sometimes reach after you navigate the maze of, like, meta-cruft. I mean you can't program if you can't even set up anything so it works right.
Reply
#2
from browser: https://pypi.python.org/pypi?%3Aaction=s...mit=search

to get a list of mp4 packages
pymovie hasn't been worked on for over 2 years, so expect it has been abandoned.
I would choose another from list  generated at start of this post.

once chosen, from command line:
pip install packagename
Reply
#3
(Nov-02-2017, 02:50 AM)Larz60+ Wrote: pymovie hasn't been worked on for over 2 years, so expect it has been abandoned.
It's not pymoive Larsz,but moivepy which is a great package.

First @ineedastupidusername you should follow this Python 3.6 and pip installation under Windows.
The you have Python and pip(package manager that automatically install stuff) working.

With programming there is always need to know basic command line stuff.
To install moivepy start cmd(command line) then pip install moviepy
Look like this:
Microsoft Windows [Version 10.0.14393]
(c) 2016 Microsoft Corporation. Med enerett.

C:\WINDOWS\system32>cd\

C:\>pip install -U moviepy
Collecting moviepy
  Using cached moviepy-0.2.3.2-py2.py3-none-any.whl
Requirement already up-to-date: imageio==2.1.2 in c:\python36\lib\site-packages (from moviepy)
Collecting numpy (from moviepy)
  Downloading numpy-1.13.3-2-cp36-none-win32.whl (6.8MB)
    100% |████████████████████████████████| 6.8MB 139kB/s
Requirement already up-to-date: tqdm==4.11.2 in c:\python36\lib\site-packages (from moviepy)
Requirement already up-to-date: decorator==4.0.11 in c:\python36\lib\site-packages (from moviepy)
Collecting pillow (from imageio==2.1.2->moviepy)
  Downloading Pillow-4.3.0-cp36-cp36m-win32.whl (1.4MB)
    100% |████████████████████████████████| 1.4MB 571kB/s
Requirement already up-to-date: olefile in c:\python36\lib\site-packages (from pillow->imageio==2.1.2->moviepy)
Installing collected packages: numpy, moviepy, pillow
  Found existing installation: numpy 1.13.0
    Uninstalling numpy-1.13.0:
      Successfully uninstalled numpy-1.13.0
  Found existing installation: Pillow 4.2.0
    Uninstalling Pillow-4.2.0:
      Successfully uninstalled Pillow-4.2.0
Successfully installed moviepy-0.2.3.2 numpy-1.13.3 pillow-4.3.0

C:\>
Then moviepy is working.
Reply
#4
Why can't one simply download a "package" folder and put that folder in the same folder as your py program and import that way? Because a package is sometimes dependent on sub-packages and maybe "pip" auto installs all the right versions of the right dependencies too? Well I have python 2.7.9 (according to top of shell, so not sure if your tutorial for 3.6 would work) and this page:
https://packaging.python.org/tutorials/i...g-packages
says 2.7.9 and beyond have pip already installed. I'm on windows 7 I think, so start/search pip. Nothing found, of course, why would that work. How am I supposed to even know where this mythical "pip" is supposedly located. Well that link above says I have it (cuz it's 2.7.9) but need to upgrade it. So I open the unholy command prompt and it says C:\users\user> and I type python -m pip install -u pip setuptools and it says "python is not recognized as an internal or external command, operable program or batch file." Great, great, making progress.
I have this theory. The new world order doesn't want people to program because they want to monopolize AI etc with no competition, not to mention the entire tyrannical corporatocracy. They would get too much flak if they directly obviously banned people from programming. Instead they create all this "pip" and wheel files etc that just makes it impossible in practice. Maybe the c language hasn't been corrupted in this way? Wall Ooh, I think I'll be using that emoticon a lot.
Reply
#5
(Nov-02-2017, 03:18 PM)ineedastupidusername Wrote: maybe "pip" auto installs all the right versions of the right dependencies too?
Yes.

It would be so most simpler if follow the tutorial and install Python 3.6.
The is just pip install moviepy, and then is Python 3.6 is in OS Path so then that command will work from anywhere in cmd.

It's just the same for 2.7,but have to do it from Scripts folder.
Pip for 2.7.9 is placed in python27/Scripts folder.

From cmd:
Microsoft Windows [Version 10.0.15063]
(c) 2017 Microsoft Corporation. Med enerett.

C:\WINDOWS\system32>cd\
C:\>cd python27/Scripts

# In Scripts folder then is just the same install
C:\Python27\Scripts>pip install moviepy
Requirement already satisfied: moviepy in c:\python27\lib\site-packages
Requirement already satisfied: numpy in c:\python27\lib\site-packages (from moviepy)
Requirement already satisfied: decorator in c:\python27\lib\site-packages (from moviepy)
Requirement already satisfied: imageio in c:\python27\lib\site-packages (from moviepy)
Requirement already satisfied: tqdm in c:\python27\lib\site-packages (from moviepy)

C:\Python27\Scripts>cd ..
# Test that it work
C:\Python27>python
Python 2.7.9 (default, Dec 10 2014, 12:24:55) [MSC v.1500 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import moviepy
>>> moviepy.__version__
'0.2.2.11'
>>>exit()
C:\Python27>
Reply
#6
OMG, I think I did it, thanks!
First I tried:
c:\python27\scripts>python -m pip install -U pip setuptools (i think that u has to be capitalized by the way)
"python is not recognized as an internal or external command operable program or batch file"
So I changed folder down 1 level:
c:\python27>python -m pip install -U pip setuptools

That worked. Then while I was still in that lower folder: (sudo) pip install moviepy ("pip was unexpected at this time"). So I had to go back UP a folder to \scripts again, then it worked. My version printed 0.2.3.2. I'm sure I'll have some other cryptic problem immediately as soon as I try anything else but I'm worn out for now.
Reply
#7
Quote:I have this theory. The new world order doesn't want people to program because they want to monopolize AI etc with no competition, not to mention the entire tyrannical corporatocracy. They would get too much flak if they directly obviously banned people from programming. Instead they create all this "pip" and wheel files etc that just makes it impossible in practice. Maybe the c language hasn't been corrupted in this way
If you never have programmed before in any language, then its a large learning curve regardless of the language. C/C++ is worse. Python you just run a command, whereas C/c++ you have to link the library, create makefiles to link the header files with the source files. Once you get the procedure down, you can do it on the fly without thinking about it.
Recommended Tutorials:
Reply
#8
It is sometimes quite frustrating when people ask for help and then refuse to follow the advise given. First off, as a new user, remove Python 2.7 and install the latest version, currently 3.6.3 using the the tutorial given earlier and repeated here: https://python-forum.io/Thread-Basic-Par...er-Windows. You are always having to change directories because your Python installation is wrong, the Environmental Variables are not set. If installed correctly, it doesn't matter where you are, you can invoke 'pip' and 'python'

Microsoft Windows [Version 10.0.14393]
(c) 2016 Microsoft Corporation. All rights reserved.

C:\WINDOWS\system32>pip list --outdated
DEPRECATION: The default format will switch to columns in the future. You can use --format=(legacy|columns) (or define a format=(legacy|columns) in your pip.conf under the
section) to disable this warning.
pytz (2017.2) - Latest: 2017.3 [wheel]

C:\WINDOWS\system32>
Microsoft Windows [Version 10.0.14393]
(c) 2016 Microsoft Corporation. All rights reserved.

C:\>pip list --outdated
DEPRECATION: The default format will switch to columns in the future. You can use --format=(legacy|columns) (or define a format=(legacy|columns) in your pip.conf under the
section) to disable this warning.
pytz (2017.2) - Latest: 2017.3 [wheel]

C:\>
C:\WINDOWS\system32>pip install -U pytz
Collecting pytz
  Downloading pytz-2017.3-py2.py3-none-any.whl (511kB)
    100% |████████████████████████████████| 512kB 998kB/s
Installing collected packages: pytz
  Found existing installation: pytz 2017.2
    Uninstalling pytz-2017.2:
      Successfully uninstalled pytz-2017.2
Successfully installed pytz-2017.3

C:\WINDOWS\system32>
Python 2 is considered to be a 'maintenance' only version and even that will be discontinued in 2020.

As a new programmer, the majority of programs you write will be run from the 'command' terminal, so you may as well add a shortcut on your desktop for it.

You should also know what operating system you are using (you think you're using Windows 7? Really?). If you have a 'My Computer' icon on your desktop, just double click it, if not, click on the 'System' icon in the Control Panel. You will then not only know what version of Windows your are using, but also what processor (32 or 64 bit) you have.

If you follow the advice you are given, you will find your need for  Wall will be greatly reduced.
If it ain't broke, I just haven't gotten to it yet.
OS: Windows 10, openSuse 42.3, freeBSD 11, Raspian "Stretch"
Python 3.6.5, IDE: PyCharm 2018 Community Edition
Reply
#9
I have like 100 small pygame programs I made in 2.7. Do I have to uninstall 2.7 and install 3.6, thus having to slightly fix all those programs whenever I run them again to make them run on 3.6? Or just have 2.7/3.6 installed simultaneously? I currently have python27 and python33 installed simultaneously, but always used 27 since I was used to it (uninstall both then install 3.6?). "your python installation is wrong"- meaning I installed it wrong, or just am using a "wrong" version- 2.7? 2.7 doesn't have "environmental variables set" as normal or just because I installed it wrong? Before the time of 3.6/pip, how did people install packages and stuff, just copy/paste the package folder into the folder your py programs are in? If so that seems simpler, what was wrong with that, maybe making sure you get all the right versions? It says windows 7 64 bit, so I guess I have to get the 64 bit python etc?
By the way I did immediately run into a cryptic problem (still in 2.7) when I tried running a test program, something about imageio needing a ffmpeg plugin, so I was back in command prompt trying to guess which directory I had to be in and what to type to get that plugin and only getting errors again.
Reply
#10
You can have as many python versions on your system as you want. He was just saying that it would be a good idea to start with 3.x because 2.x is going to be dead soon.

Quote: Before the time of 3.6/pip, how did people install packages and stuff
pip has been packaged with python since 2.7.9 and 3.4 but has been around since way before that.

This tutorial should be how you install python properly where it adds pytohn to the PATH, makes sure pip is installed, makes sure you add a custom install path that is short and easy to navigate to in command prompt, etc.

Before pip was setuptools and easy_install
pip is the "even easier installer"

Quote:It says windows 7 64 bit, so I guess I have to get the 64 bit python etc?
Thats not definite on what python is either. Even though you have a 64 bit operating system, it still can run 32 bit applications. You can have a 64 bit OS running a 32 bit python, but cannot have a 32 bit OS running a 64 bit python, etc. And yes people do makes these mistakes when downloading 3rd party libs. But that is where pip comes in, it downloads the proper one for you.

Their website says it should handle ffmpeg
Quote:MoviePy depends on the software FFMPEG for video reading and writing. You don’t need to worry about that, as FFMPEG should be automatically downloaded/installed by ImageIO during your first use of MoviePy (it takes a few seconds). If you want to use a specific version of FFMPEG, you can set the FFMPEG_BINARY environment variable See moviepy/config_defaults.py for details.
What is the exact error you get? It would be better if we can see what your input/output of the command prompt is when you get such issues.

By the way you dont need sudo. sudo is for (admin) privledges on unix systems. If your on windows you can ignore that.
Recommended Tutorials:
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  trouble installing python package Tuxedo 1 3,240 Apr-07-2021, 09:07 AM
Last Post: Larz60+
  Installing package in Anaconda on an Intranet Computer Secret 1 1,936 Sep-17-2020, 02:16 PM
Last Post: Larz60+
  Error when installing Seaborn package using pip chawkins 3 5,597 Jul-16-2018, 12:12 AM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020