2018-10-16 23:00:18 +01:00
|
|
|
{ stdenv
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2019-04-19 16:10:20 +01:00
|
|
|
, pythonAtLeast
|
2018-10-16 23:00:18 +01:00
|
|
|
, numpy
|
|
|
|
, decorator
|
|
|
|
, imageio
|
2019-04-19 02:31:56 +01:00
|
|
|
, imageio-ffmpeg
|
|
|
|
, proglog
|
|
|
|
, requests
|
2018-10-16 23:00:18 +01:00
|
|
|
, tqdm
|
2019-04-19 17:44:36 +01:00
|
|
|
# Advanced image processing (triples size of output)
|
|
|
|
, advancedProcessing ? false
|
2019-11-28 22:16:04 +00:00
|
|
|
, opencv3 ? null
|
2019-04-19 17:44:36 +01:00
|
|
|
, scikitimage ? null
|
|
|
|
, scikitlearn ? null
|
|
|
|
, scipy ? null
|
|
|
|
, matplotlib ? null
|
|
|
|
, youtube-dl ? null
|
2018-10-16 23:00:18 +01:00
|
|
|
}:
|
|
|
|
|
2019-04-19 17:44:36 +01:00
|
|
|
assert advancedProcessing -> (
|
2019-11-28 22:16:04 +00:00
|
|
|
opencv3 != null && scikitimage != null && scikitlearn != null
|
2019-04-19 17:44:36 +01:00
|
|
|
&& scipy != null && matplotlib != null && youtube-dl != null);
|
|
|
|
|
2018-10-16 23:00:18 +01:00
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "moviepy";
|
2020-04-07 07:28:03 +01:00
|
|
|
version = "1.0.2";
|
2018-10-16 23:00:18 +01:00
|
|
|
|
2019-04-19 16:10:20 +01:00
|
|
|
disabled = !(pythonAtLeast "3.4");
|
|
|
|
|
2018-10-16 23:00:18 +01:00
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-04-07 07:28:03 +01:00
|
|
|
sha256 = "0ajw2xmcd962qw2kxxnbp08l5vgk5k78sls9bb227lw8aa51ln80";
|
2018-10-16 23:00:18 +01:00
|
|
|
};
|
|
|
|
|
2019-04-19 17:44:36 +01:00
|
|
|
# No tests, require network connection
|
2018-10-16 23:00:18 +01:00
|
|
|
doCheck = false;
|
2019-04-19 17:44:36 +01:00
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
numpy decorator imageio imageio-ffmpeg tqdm requests proglog
|
|
|
|
] ++ (stdenv.lib.optionals advancedProcessing [
|
2019-11-28 22:16:04 +00:00
|
|
|
opencv3 scikitimage scikitlearn scipy matplotlib youtube-dl
|
2019-04-19 17:44:36 +01:00
|
|
|
]);
|
2018-10-16 23:00:18 +01:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Video editing with Python";
|
2020-03-27 23:05:50 +00:00
|
|
|
homepage = "https://zulko.github.io/moviepy/";
|
2018-10-16 23:00:18 +01:00
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|