diff --git a/.gitignore b/.gitignore index b2b9c4b..b40b8b0 100644 --- a/.gitignore +++ b/.gitignore @@ -133,5 +133,7 @@ dmypy.json models/* data/* .idea -src/nerf/cache/ -src/nerf/logs/ \ No newline at end of file +**/cache/ +**/*logs/ +.venv/ + diff --git a/.python-version b/.python-version new file mode 100644 index 0000000..d2577d9 --- /dev/null +++ b/.python-version @@ -0,0 +1 @@ +3.7.7 diff --git a/data b/data deleted file mode 120000 index dd97660..0000000 --- a/data +++ /dev/null @@ -1 +0,0 @@ -/home/nerfteam/data \ No newline at end of file diff --git a/poetry.lock b/poetry.lock index c731793..7453503 100644 --- a/poetry.lock +++ b/poetry.lock @@ -44,13 +44,29 @@ version = "0.10.0" [package.dependencies] six = "*" +[[package]] +category = "main" +description = "Decorators for Humans" +name = "decorator" +optional = false +python-versions = ">=2.6, !=3.0.*, !=3.1.*" +version = "4.4.2" + +[[package]] +category = "main" +description = "Freetype python bindings" +name = "freetype-py" +optional = false +python-versions = "*" +version = "2.1.0.post1" + [[package]] category = "main" description = "Google Authentication Library" name = "google-auth" optional = false python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" -version = "1.14.1" +version = "1.15.0" [package.dependencies] cachetools = ">=2.0.0,<5.0" @@ -80,7 +96,7 @@ description = "HTTP/2-based RPC framework" name = "grpcio" optional = false python-versions = "*" -version = "1.28.1" +version = "1.29.0" [package.dependencies] six = ">=1.5.2" @@ -93,6 +109,20 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" version = "2.9" +[[package]] +category = "main" +description = "Image transformation, compression, and decompression codecs" +name = "imagecodecs" +optional = false +python-versions = ">=3.6" +version = "2020.2.18" + +[package.dependencies] +numpy = ">=1.15" + +[package.extras] +all = ["matplotlib (>=3.1)", "tifffile (>=2019.7.2)"] + [[package]] category = "main" description = "Library for reading and writing a wide range of image, video, scientific, and volumetric data formats." @@ -112,6 +142,22 @@ full = ["astropy", "gdal", "imageio-ffmpeg", "itk"] gdal = ["gdal"] itk = ["itk"] +[[package]] +category = "main" +description = "Read metadata from Python packages" +marker = "python_version < \"3.8\"" +name = "importlib-metadata" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" +version = "1.6.0" + +[package.dependencies] +zipp = ">=0.5" + +[package.extras] +docs = ["sphinx", "rst.linker"] +testing = ["packaging", "importlib-resources"] + [[package]] category = "main" description = "A fast implementation of the Cassowary constraint solver" @@ -126,10 +172,12 @@ description = "Python implementation of Markdown." name = "markdown" optional = false python-versions = ">=3.5" -version = "3.2.1" +version = "3.2.2" [package.dependencies] -setuptools = ">=36" +[package.dependencies.importlib-metadata] +python = "<3.8" +version = "*" [package.extras] testing = ["coverage", "pyyaml"] @@ -149,6 +197,30 @@ numpy = ">=1.11" pyparsing = ">=2.0.1,<2.0.4 || >2.0.4,<2.1.2 || >2.1.2,<2.1.6 || >2.1.6" python-dateutil = ">=2.1" +[[package]] +category = "main" +description = "Python package for creating and manipulating graphs and networks" +name = "networkx" +optional = false +python-versions = ">=3.5" +version = "2.4" + +[package.dependencies] +decorator = ">=4.3.0" + +[package.extras] +all = ["numpy", "scipy", "pandas", "matplotlib", "pygraphviz", "pydot", "pyyaml", "gdal", "lxml", "pytest"] +gdal = ["gdal"] +lxml = ["lxml"] +matplotlib = ["matplotlib"] +numpy = ["numpy"] +pandas = ["pandas"] +pydot = ["pydot"] +pygraphviz = ["pygraphviz"] +pytest = ["pytest"] +pyyaml = ["pyyaml"] +scipy = ["scipy"] + [[package]] category = "main" description = "NumPy is the fundamental package for array computing with Python." @@ -195,7 +267,7 @@ description = "Protocol Buffers" name = "protobuf" optional = false python-versions = "*" -version = "3.11.3" +version = "3.12.0" [package.dependencies] setuptools = "*" @@ -220,6 +292,37 @@ version = "0.2.8" [package.dependencies] pyasn1 = ">=0.4.6,<0.5.0" +[[package]] +category = "main" +description = "python library for reading and writing collada documents" +name = "pycollada" +optional = false +python-versions = "*" +version = "0.7.1" + +[package.dependencies] +python-dateutil = ">=2.2" + +[package.extras] +prettyprint = ["lxml"] +validation = ["lxml"] + +[[package]] +category = "main" +description = "Cross-platform windowing and multimedia library" +name = "pyglet" +optional = false +python-versions = "*" +version = "1.5.5" + +[[package]] +category = "main" +description = "Standard OpenGL bindings for Python" +name = "pyopengl" +optional = false +python-versions = "*" +version = "3.1.0" + [[package]] category = "main" description = "Python parsing module" @@ -228,6 +331,30 @@ optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" version = "2.4.7" +[[package]] +category = "main" +description = "Easy-to-use Python renderer for 3D visualization" +name = "pyrender" +optional = false +python-versions = "*" +version = "0.1.40" + +[package.dependencies] +Pillow = "*" +PyOpenGL = "3.1.0" +freetype-py = "*" +imageio = "*" +networkx = "*" +numpy = "*" +pyglet = ">=1.4.10" +scipy = "*" +six = "*" +trimesh = "*" + +[package.extras] +dev = ["flake8", "pre-commit", "pytest", "pytest-cov", "tox"] +docs = ["sphinx", "sphinx-rtd-theme", "sphinx-automodapi"] + [[package]] category = "main" description = "Extensions to the standard Python datetime module" @@ -239,6 +366,17 @@ version = "2.8.1" [package.dependencies] six = ">=1.5" +[[package]] +category = "main" +description = "PyWavelets, wavelet transform module" +name = "pywavelets" +optional = false +python-versions = ">=3.5" +version = "1.1.1" + +[package.dependencies] +numpy = ">=1.13.3" + [[package]] category = "main" description = "YAML parser and emitter for Python" @@ -291,6 +429,40 @@ version = "4.0" [package.dependencies] pyasn1 = ">=0.1.3" +[[package]] +category = "main" +description = "Image processing in Python" +name = "scikit-image" +optional = false +python-versions = ">=3.6" +version = "0.17.2" + +[package.dependencies] +PyWavelets = ">=1.1.1" +imageio = ">=2.3.0" +matplotlib = ">=2.0.0,<3.0.0 || >3.0.0" +networkx = ">=2.0" +numpy = ">=1.15.1" +pillow = ">=4.3.0,<7.1.0 || >7.1.0,<7.1.1 || >7.1.1" +scipy = ">=1.0.1" +tifffile = ">=2019.7.26" + +[package.extras] +docs = ["sphinx (>=1.8,<=2.4.4)", "numpydoc (>=0.9)", "sphinx-gallery (>=0.3.1)", "sphinx-copybutton", "pytest-runner", "scikit-learn", "matplotlib (>=3.0.1)", "dask (>=0.15.0)", "cloudpickle (>=0.2.1)", "pandas (>=0.23.0)", "seaborn (>=0.7.1)", "pooch (>=0.5.2)"] +optional = ["simpleitk", "astropy (>=1.2.0)", "qtpy", "pyamg", "dask (>=0.15.0)", "cloudpickle (>=0.2.1)", "pooch (>=0.5.2)"] +test = ["pytest (!=3.7.3)", "pytest-cov", "pytest-localserver", "flake8", "codecov"] + +[[package]] +category = "main" +description = "SciPy: Scientific Library for Python" +name = "scipy" +optional = false +python-versions = ">=3.5" +version = "1.4.1" + +[package.dependencies] +numpy = ">=1.13.3" + [[package]] category = "main" description = "Python 2 and 3 compatibility utilities" @@ -335,27 +507,26 @@ version = "1.6.0.post3" [[package]] category = "main" -description = "Tensors and Dynamic neural networks in Python with strong GPU acceleration" -name = "torch" +description = "Read and write TIFF(r) files" +name = "tifffile" optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" -version = "1.4.0" +python-versions = ">=3.6" +version = "2020.5.11" -[[package]] -category = "main" -description = "" -name = "torchsearchsorted" -optional = false -python-versions = "*" -version = "1.1" +[package.dependencies] +imagecodecs = ">=2020.2.18" +numpy = ">=1.15.1" [package.extras] -test = ["pytest"] +all = ["matplotlib (>=3.1)"] -[package.source] -reference = "1e0ffc3e0663ffda318b4e28348efd90313d08f3" -type = "git" -url = "https://github.com/aliutkus/torchsearchsorted" +[[package]] +category = "main" +description = "Tensors and Dynamic neural networks in Python with strong GPU acceleration" +name = "torch" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" +version = "1.4.0" [[package]] category = "main" @@ -385,6 +556,24 @@ version = "4.46.0" [package.extras] dev = ["py-make (>=0.1.0)", "twine", "argopt", "pydoc-markdown"] +[[package]] +category = "main" +description = "Import, export, process, analyze and view triangular meshes." +name = "trimesh" +optional = false +python-versions = "*" +version = "3.6.39" + +[package.dependencies] +numpy = "*" +setuptools = "*" + +[package.extras] +all = ["pillow", "requests", "python-fcl", "scikit-image", "jsonschema", "triangle", "pycollada", "pyglet", "sympy", "msgpack", "colorlog", "lxml", "meshio", "glooey", "scipy", "rtree", "svg.path", "psutil", "shapely", "setuptools", "networkx", "chardet", "xxhash"] +docs = ["sphinx", "recommonmark", "pyopenssl", "sphinx-rtd-theme", "scipy", "jupyter", "networkx", "pypandoc", "numpy", "autodocsumm"] +easy = ["pycollada", "xxhash", "sympy", "msgpack", "colorlog", "lxml", "pillow", "scipy", "requests", "rtree", "svg.path", "shapely", "setuptools", "jsonschema", "networkx", "chardet", "pyglet"] +test = ["pytest-cov", "coveralls", "pyinstrument", "pytest"] + [[package]] category = "main" description = "HTTP library with thread-safe connection pooling, file post, and more." @@ -422,8 +611,21 @@ version = "0.34.2" [package.extras] test = ["pytest (>=3.0.0)", "pytest-cov"] +[[package]] +category = "main" +description = "Backport of pathlib-compatible object wrapper for zip files" +marker = "python_version < \"3.8\"" +name = "zipp" +optional = false +python-versions = ">=3.6" +version = "3.1.0" + +[package.extras] +docs = ["sphinx", "jaraco.packaging (>=3.2)", "rst.linker (>=1.9)"] +testing = ["jaraco.itertools", "func-timeout"] + [metadata] -content-hash = "70bb88d6ce4509421ccfb8dfe0e2dd03ae460b0a72d5642594f8ec16ecfa319f" +content-hash = "557540e621bea76ffa8489947cfc9538cb0c781007faedf02149c7d201dcc480" python-versions = "^3.7" [metadata.files] @@ -446,55 +648,96 @@ cycler = [ {file = "cycler-0.10.0-py2.py3-none-any.whl", hash = "sha256:1d8a5ae1ff6c5cf9b93e8811e581232ad8920aeec647c37316ceac982b08cb2d"}, {file = "cycler-0.10.0.tar.gz", hash = "sha256:cd7b2d1018258d7247a71425e9f26463dfb444d411c39569972f4ce586b0c9d8"}, ] +decorator = [ + {file = "decorator-4.4.2-py2.py3-none-any.whl", hash = "sha256:41fa54c2a0cc4ba648be4fd43cff00aedf5b9465c9bf18d64325bc225f08f760"}, + {file = "decorator-4.4.2.tar.gz", hash = "sha256:e3a62f0520172440ca0dcc823749319382e377f37f140a0b99ef45fecb84bfe7"}, +] +freetype-py = [ + {file = "freetype-py-2.1.0.post1.tar.gz", hash = "sha256:76383bb3e59efa6ce0be1797ed70207d7d1e421611df3aceb269673c4a77c2cc"}, + {file = "freetype_py-2.1.0.post1-py2.py3-none-any.whl", hash = "sha256:0f14ffc1715e3d0f01e7c9d07980b10b7143595d9322bb6da3fc74db5251fa8c"}, + {file = "freetype_py-2.1.0.post1-py2.py3-none-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:2fa866dd3d8beb73d03f0cf6b7cc51d0cd0ab9c8674c1d8bee2a1b299ee0731c"}, + {file = "freetype_py-2.1.0.post1-py2.py3-none-manylinux1_i686.whl", hash = "sha256:be7a97a964a23d41d7eed4fc834b243871845115728ef41390b9efede588e854"}, + {file = "freetype_py-2.1.0.post1-py2.py3-none-manylinux1_x86_64.whl", hash = "sha256:84e9879bb5f87dc1eb5342230a13e7ea10f520aa06a4d1c7b298208bbac08110"}, + {file = "freetype_py-2.1.0.post1-py2.py3-none-win32.whl", hash = "sha256:d179759b245bb01f5603acd071aea99d97d993a28c4e71fdc4bd7530c49931f9"}, + {file = "freetype_py-2.1.0.post1-py2.py3-none-win_amd64.whl", hash = "sha256:eda77d57acdfe74d1cf3958b5fb5aaea21a2866f4e8d7632c06123d6014f9e0c"}, +] google-auth = [ - {file = "google-auth-1.14.1.tar.gz", hash = "sha256:e63b2210e03c4ed829063b72c4af0c4b867c2788efb3210b6b9439b488bd3afd"}, - {file = "google_auth-1.14.1-py2.py3-none-any.whl", hash = "sha256:0c41a453b9a8e77975bfa436b8daedac00aed1c545d84410daff8272fff40fbb"}, + {file = "google-auth-1.15.0.tar.gz", hash = "sha256:fbf25fee328c0828ef293459d9c649ef84ee44c0b932bb999d19df0ead1b40cf"}, + {file = "google_auth-1.15.0-py2.py3-none-any.whl", hash = "sha256:73b141d122942afe12e8bfdcb6900d5df35c27d39700f078363ba0b1298ad33b"}, ] google-auth-oauthlib = [ {file = "google-auth-oauthlib-0.4.1.tar.gz", hash = "sha256:88d2cd115e3391eb85e1243ac6902e76e77c5fe438b7276b297fbe68015458dd"}, {file = "google_auth_oauthlib-0.4.1-py2.py3-none-any.whl", hash = "sha256:a92a0f6f41a0fb6138454fbc02674e64f89d82a244ea32f98471733c8ef0e0e1"}, ] grpcio = [ - {file = "grpcio-1.28.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:085bbf7fd0070b8d65e84aa32979f17cfe624d27b5ce23955ef770c19d2d9623"}, - {file = "grpcio-1.28.1-cp27-cp27m-manylinux2010_i686.whl", hash = "sha256:f80d10bdf1a306f7063046321fd4efc7732a606acdd4e6259b8a37349079b704"}, - {file = "grpcio-1.28.1-cp27-cp27m-manylinux2010_x86_64.whl", hash = "sha256:e9439d7b801c86df13c6cbb4c5a7e181c058f3c119d5e119a94a5f3090a8f060"}, - {file = "grpcio-1.28.1-cp27-cp27m-win32.whl", hash = "sha256:271abbe28eb99fa5c70b3f272c0c66b67dab7bb11e1d29d8e616b4e0e099d29a"}, - {file = "grpcio-1.28.1-cp27-cp27m-win_amd64.whl", hash = "sha256:df749ee982ec35ab76d37a1e637b10a92b4573e2b4e1f86a5fa8a1273c40a850"}, - {file = "grpcio-1.28.1-cp27-cp27mu-linux_armv7l.whl", hash = "sha256:0ef6b380a588c2c6b29c6cfa0ba7f5d367beb33d5504bcc68658fa241ad498d2"}, - {file = "grpcio-1.28.1-cp27-cp27mu-manylinux2010_i686.whl", hash = "sha256:c6565cc92853af13237b2233f331efdad07339d27fe1f5f74256bfde7dc2f587"}, - {file = "grpcio-1.28.1-cp27-cp27mu-manylinux2010_x86_64.whl", hash = "sha256:97b5612fc5d4bbf0490a2d80bed5eab5b59112ef1640440c1a9ac824bafa6968"}, - {file = "grpcio-1.28.1-cp35-cp35m-linux_armv7l.whl", hash = "sha256:4bef0756b9e0df78e8d67a5b1e0e89b7daf41525d575f74e1f14a993c55b680d"}, - {file = "grpcio-1.28.1-cp35-cp35m-macosx_10_7_intel.whl", hash = "sha256:0c130204ff5de0b9f041bf3126db0d29369d69883592e4b0d3c19868ba0ced7e"}, - {file = "grpcio-1.28.1-cp35-cp35m-manylinux2010_i686.whl", hash = "sha256:70ff2df0c1795c5cf585a72d95bb458838b40bad5653c314b9067ba819e918f9"}, - {file = "grpcio-1.28.1-cp35-cp35m-manylinux2010_x86_64.whl", hash = "sha256:a35f8f4a0334ed8b05db90383aecef8e49923ab430689a4360a74052f3a89cf4"}, - {file = "grpcio-1.28.1-cp35-cp35m-win32.whl", hash = "sha256:f83b0c91796eb42865451a20e82246011078ba067ea0744f7301e12a94ae2e1b"}, - {file = "grpcio-1.28.1-cp35-cp35m-win_amd64.whl", hash = "sha256:c2e53eb253840f05278a8410628419ba7060815f86d48c9d83b6047de21c9956"}, - {file = "grpcio-1.28.1-cp36-cp36m-linux_armv7l.whl", hash = "sha256:16f5523dacae5aaeda4cf900da7e980747f663298c38c18eb4e5317704aa007a"}, - {file = "grpcio-1.28.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:3c7864d5ae63b787001b01b376f6315aef1a015aa9c809535235ed0ead907919"}, - {file = "grpcio-1.28.1-cp36-cp36m-manylinux2010_i686.whl", hash = "sha256:c3645887db3309fc87c3db740b977d403fb265ebab292f1f6a926c4661231fd5"}, - {file = "grpcio-1.28.1-cp36-cp36m-manylinux2010_x86_64.whl", hash = "sha256:16e1edb367763ea08d0994d4635ec05f4f8db9db59c39304b061097e3b93df43"}, - {file = "grpcio-1.28.1-cp36-cp36m-win32.whl", hash = "sha256:5c2e81b6ab9768c43f2ca1c9a4c925823aad79ae95efb351007df4b92ebce592"}, - {file = "grpcio-1.28.1-cp36-cp36m-win_amd64.whl", hash = "sha256:245564713cb4ac7bccb0f11be63781beb62299a44d8ab69031c859dbd9461728"}, - {file = "grpcio-1.28.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:f493ac4754717f25ace3614a51dd408a32b8bff3c9c0c85e9356e7e0a120a8c8"}, - {file = "grpcio-1.28.1-cp37-cp37m-manylinux2010_i686.whl", hash = "sha256:3366bd6412c1e73acb1ee27d7f0c7d7dbee118ad8d98c957c8173691b2effeec"}, - {file = "grpcio-1.28.1-cp37-cp37m-manylinux2010_x86_64.whl", hash = "sha256:4fe081862e58b8fbef0e479aefc9a64f8f17f53074df1085d8c1fe825a6e5df4"}, - {file = "grpcio-1.28.1-cp37-cp37m-win32.whl", hash = "sha256:3893b39a0a17d857dc3a42fdb02a26aa53a59bfce49987187bcc0261647f1f55"}, - {file = "grpcio-1.28.1-cp37-cp37m-win_amd64.whl", hash = "sha256:2e1b01cba26988c811c7fb91a0bca19c9afb776cc3d228993f08d324bdd0510a"}, - {file = "grpcio-1.28.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:181b5078cf568f37915b8a118afcef5fc9f3128c59c38998ed93e7dd793e3928"}, - {file = "grpcio-1.28.1-cp38-cp38-manylinux2010_i686.whl", hash = "sha256:aafe85a8210dfa1da3c46831b7f00c3735240b7b028eeba339eaea6ffdb593fb"}, - {file = "grpcio-1.28.1-cp38-cp38-manylinux2010_x86_64.whl", hash = "sha256:42c6716adf3ec1f608b2b56e885f26dd86e80d2fc1617f51fc92d1b0b649e28e"}, - {file = "grpcio-1.28.1-cp38-cp38-win32.whl", hash = "sha256:505a8d1b4ac571a51f10c4c995d5d4714f03c886604dc3c097ef5fd57bcfcf0b"}, - {file = "grpcio-1.28.1-cp38-cp38-win_amd64.whl", hash = "sha256:0ae207a47ec0ad66eb1f53a27d566674d13a236c62ced409891335318ea9b8c5"}, - {file = "grpcio-1.28.1.tar.gz", hash = "sha256:cbc322c5d5615e67c2a15be631f64e6c2bab8c12505bc7c150948abdaa0bdbac"}, + {file = "grpcio-1.29.0-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:e90f3d11185c36593186e5ff1f581acc6ddfa4190f145b0366e579de1f52803b"}, + {file = "grpcio-1.29.0-cp27-cp27m-manylinux2010_i686.whl", hash = "sha256:5024b26e17a1bfc9390fb3b8077bf886eee02970af780fd23072970ef08cefe8"}, + {file = "grpcio-1.29.0-cp27-cp27m-manylinux2010_x86_64.whl", hash = "sha256:23bc395a32c2465564cb242e48bdd2fdbe5a4aebf307649a800da1b971ee7f29"}, + {file = "grpcio-1.29.0-cp27-cp27m-win32.whl", hash = "sha256:886d48c32960b39e059494637eb0157a694956248d03b0de814447c188b74799"}, + {file = "grpcio-1.29.0-cp27-cp27m-win_amd64.whl", hash = "sha256:da0ca9b1089d00e39a8b83deec799a4e5c37ec1b44d804495424acde50531868"}, + {file = "grpcio-1.29.0-cp27-cp27mu-linux_armv7l.whl", hash = "sha256:ebf0ccb782027ef9e213e03b6d00bbd8dabd80959db7d468c0738e6d94b5204c"}, + {file = "grpcio-1.29.0-cp27-cp27mu-manylinux2010_i686.whl", hash = "sha256:2637ce96b7c954d2b71060f50eb4c72f81668f1b2faa6cbdc74677e405978901"}, + {file = "grpcio-1.29.0-cp27-cp27mu-manylinux2010_x86_64.whl", hash = "sha256:75b2247307a7ecaf6abc9eb2bd04af8f88816c111b87bf0044d7924396e9549c"}, + {file = "grpcio-1.29.0-cp35-cp35m-linux_armv7l.whl", hash = "sha256:7bf3cb1e0f4a9c89f7b748583b994bdce183103d89d5ff486da48a7668a052c7"}, + {file = "grpcio-1.29.0-cp35-cp35m-macosx_10_7_intel.whl", hash = "sha256:a6dddb177b3cfa0cfe299fb9e07d6a3382cc79466bef48fe9c4326d5c5b1dcb8"}, + {file = "grpcio-1.29.0-cp35-cp35m-manylinux2010_i686.whl", hash = "sha256:b49f243936b0f6ae8eb6adf88a1e54e736f1c6724a1bff6b591d105d708263ad"}, + {file = "grpcio-1.29.0-cp35-cp35m-manylinux2010_x86_64.whl", hash = "sha256:9cfb4b71cc3c8757f137d47000f9d90d4bd818733f9ab4f78bd447e052a4cb9a"}, + {file = "grpcio-1.29.0-cp35-cp35m-win32.whl", hash = "sha256:10cdc8946a7c2284bbc8e16d346eaa2beeaae86ea598f345df86d4ef7dfedb84"}, + {file = "grpcio-1.29.0-cp35-cp35m-win_amd64.whl", hash = "sha256:806c9759f5589b3761561187408e0313a35c5c53f075c7590effab8d27d67dfe"}, + {file = "grpcio-1.29.0-cp36-cp36m-linux_armv7l.whl", hash = "sha256:57c8cc2ae8cb94c3a89671af7e1380a4cdfcd6bab7ba303f4461ec32ded250ae"}, + {file = "grpcio-1.29.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:97b72bf2242a351a89184134adbb0ae3b422e6893c6c712bc7669e2eab21501b"}, + {file = "grpcio-1.29.0-cp36-cp36m-manylinux2010_i686.whl", hash = "sha256:517538a54afdd67162ea2af1ac3326c0752c5d13e6ddadbc4885f6a28e91ab28"}, + {file = "grpcio-1.29.0-cp36-cp36m-manylinux2010_x86_64.whl", hash = "sha256:eede3039c3998e2cc0f6713f4ac70f235bd32967c9b958a17bf937aceebc12c3"}, + {file = "grpcio-1.29.0-cp36-cp36m-win32.whl", hash = "sha256:54e4658c09084b09cd83a5ea3a8bce78e4031ff1010bb8908c399a22a76a6f08"}, + {file = "grpcio-1.29.0-cp36-cp36m-win_amd64.whl", hash = "sha256:7e02a7c40304eecee203f809a982732bd37fad4e798acad98fe73c66e44ff2db"}, + {file = "grpcio-1.29.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:ff7931241351521b8df01d7448800ce0d59364321d8d82c49b826d455678ff08"}, + {file = "grpcio-1.29.0-cp37-cp37m-manylinux2010_i686.whl", hash = "sha256:5fd9ffe938e9225c654c60eb21ff011108cc27302db85200413807e0eda99a4a"}, + {file = "grpcio-1.29.0-cp37-cp37m-manylinux2010_x86_64.whl", hash = "sha256:9ef0370bcf629ece4e7e37796e4604e2514b920669be2911fc3f9c163a73a57b"}, + {file = "grpcio-1.29.0-cp37-cp37m-win32.whl", hash = "sha256:3d8c510b6eabce5192ce126003d74d7751c7218d3e2ad39fcf02400d7ec43abe"}, + {file = "grpcio-1.29.0-cp37-cp37m-win_amd64.whl", hash = "sha256:81bbf78a399e0ee516c81ddad8601f12af3fc9b30f2e4b2fbd64efd327304a4d"}, + {file = "grpcio-1.29.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:80e9f9f6265149ca7c84e1c8c31c2cf3e2869c45776fbe8880a3133a11d6d290"}, + {file = "grpcio-1.29.0-cp38-cp38-manylinux2010_i686.whl", hash = "sha256:524ae8d3da61b856cf08abb3d0947df05402919e4be1f88328e0c1004031f72e"}, + {file = "grpcio-1.29.0-cp38-cp38-manylinux2010_x86_64.whl", hash = "sha256:c3a0ef12ee86f6e72db50e01c3dba7735a76d8c30104b9b0f7fd9d65ceb9d93f"}, + {file = "grpcio-1.29.0-cp38-cp38-win32.whl", hash = "sha256:97fcbdf1f12e0079d26db73da11ee35a09adc870b1e72fbff0211f6a8003a4e8"}, + {file = "grpcio-1.29.0-cp38-cp38-win_amd64.whl", hash = "sha256:b85f355fc24b68a6c52f2750e7141110d1fcd07dfdc9b282de0000550fe0511b"}, + {file = "grpcio-1.29.0.tar.gz", hash = "sha256:a97ea91e31863c9a3879684b5fb3c6ab4b17c5431787548fc9f52b9483ea9c25"}, ] idna = [ {file = "idna-2.9-py2.py3-none-any.whl", hash = "sha256:a068a21ceac8a4d63dbfd964670474107f541babbd2250d61922f029858365fa"}, {file = "idna-2.9.tar.gz", hash = "sha256:7588d1c14ae4c77d74036e8c22ff447b26d0fde8f007354fd48a7814db15b7cb"}, ] +imagecodecs = [ + {file = "imagecodecs-2020.2.18-cp36-cp36m-macosx_10_13_intel.whl", hash = "sha256:286b87ee09506c35f099585e6b5ce245fb62c2a826aac4e0497cdfdfba631cc7"}, + {file = "imagecodecs-2020.2.18-cp36-cp36m-macosx_10_9_intel.whl", hash = "sha256:f6ac9dd40e1cdb72842fb72f147e8a51a1874c8f375629524566b388e841be20"}, + {file = "imagecodecs-2020.2.18-cp36-cp36m-manylinux2010_i686.whl", hash = "sha256:c7367e01a199228b6526f05dc7fe7a85adac19f1b19e08a99edbdd2523cfcdc4"}, + {file = "imagecodecs-2020.2.18-cp36-cp36m-manylinux2010_x86_64.whl", hash = "sha256:f6722cd6a73501c508b361f485259f172898d3cf2530e6de71f3e89394a0a713"}, + {file = "imagecodecs-2020.2.18-cp36-cp36m-manylinux2014_x86_64.whl", hash = "sha256:eedf5be2c9c65a0d92970bda98dfd7e9525c137e631e1956753bb6ce369b08f9"}, + {file = "imagecodecs-2020.2.18-cp36-cp36m-win32.whl", hash = "sha256:d1b0b2de7be918a8eada62c8d2339931381c86dbd43216a064e35ace5957e350"}, + {file = "imagecodecs-2020.2.18-cp36-cp36m-win_amd64.whl", hash = "sha256:22f3c39755752fe3a91a92fcf24002ca57a51efca1ab99e9919cf783f90b4026"}, + {file = "imagecodecs-2020.2.18-cp37-cp37m-macosx_10_13_intel.whl", hash = "sha256:2bda6c7b13be73dfd202b3c23dc4b3003fdc02209835e348e4bd31ddca124d76"}, + {file = "imagecodecs-2020.2.18-cp37-cp37m-macosx_10_9_intel.whl", hash = "sha256:cf855a00bf5cb5a7cf1d608e7588ddc535d714e5422c3095dd811829b559f237"}, + {file = "imagecodecs-2020.2.18-cp37-cp37m-manylinux2010_i686.whl", hash = "sha256:c5667d4b8e97cf10b3754f5e8159d60620cdd35052ffc298346273d42284430f"}, + {file = "imagecodecs-2020.2.18-cp37-cp37m-manylinux2010_x86_64.whl", hash = "sha256:9742b392640c1b2d05c6aaad956bd7e3bf461c7e0f403f7b25ee464a5c949c8c"}, + {file = "imagecodecs-2020.2.18-cp37-cp37m-manylinux2014_x86_64.whl", hash = "sha256:2c130b89fcb70bab3aa57ee0671423ab0e053c6ff7ed26646bf425592fa3116d"}, + {file = "imagecodecs-2020.2.18-cp37-cp37m-win32.whl", hash = "sha256:adc09e5f9af6927eccc35d60ae1ec422cd9791cee4d5456d39af6903dff19477"}, + {file = "imagecodecs-2020.2.18-cp37-cp37m-win_amd64.whl", hash = "sha256:fbdd0d42aa3c984377421767a892e77c40249870425aca0ba5629bdcd57d3ae4"}, + {file = "imagecodecs-2020.2.18-cp38-cp38-macosx_10_13_x86_64.whl", hash = "sha256:6275213bd611156fa2fd73ce81b29ca708c4344d36fe3686f567cd104ccf4d18"}, + {file = "imagecodecs-2020.2.18-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:6f63ae2592086b1abbd40b699816c054dc7aad616df2b14c2e15cd2372b77653"}, + {file = "imagecodecs-2020.2.18-cp38-cp38-manylinux2010_i686.whl", hash = "sha256:9a9abc5498121f0005fb00dfbed57a062337445d32a39569e4378286b503125b"}, + {file = "imagecodecs-2020.2.18-cp38-cp38-manylinux2010_x86_64.whl", hash = "sha256:91eb82b0167ff022a6a8dcf86e5871b635bfbe96801557e00d6b1e2a10ac25dd"}, + {file = "imagecodecs-2020.2.18-cp38-cp38-manylinux2014_x86_64.whl", hash = "sha256:e0f3cfc2fc77c19118e173dca6af0dbed4a3cef75d3296762db687fd00fb7921"}, + {file = "imagecodecs-2020.2.18-cp38-cp38-win32.whl", hash = "sha256:e8f460145258a28544d4119f58cab2daf87ac6653429ab9df7dff7d2cc30714f"}, + {file = "imagecodecs-2020.2.18-cp38-cp38-win_amd64.whl", hash = "sha256:0538f7a4def1f6745b2d83d21883dcd61e82bc8faaca810e3a35e6b551b455d1"}, + {file = "imagecodecs-2020.2.18.tar.gz", hash = "sha256:c019b19438dff31365fee3002b438992c16bc9955a036f466c600d80699cb5a2"}, +] imageio = [ {file = "imageio-2.8.0-py3-none-any.whl", hash = "sha256:1e4ab29b3775bb093c7a35854a0412857145450183344678829b30e72263b001"}, {file = "imageio-2.8.0.tar.gz", hash = "sha256:fb5fd6d3d17126bbaac9af29fe340e2c97a196eb9416d4f28c0e543744a152cf"}, ] +importlib-metadata = [ + {file = "importlib_metadata-1.6.0-py2.py3-none-any.whl", hash = "sha256:2a688cbaa90e0cc587f1df48bdc97a6eadccdcd9c35fb3f976a09e3b5016d90f"}, + {file = "importlib_metadata-1.6.0.tar.gz", hash = "sha256:34513a8a0c4962bc66d35b359558fd8a5e10cd472d37aec5f66858addef32c1e"}, +] kiwisolver = [ {file = "kiwisolver-1.2.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:443c2320520eda0a5b930b2725b26f6175ca4453c61f739fef7a5847bd262f74"}, {file = "kiwisolver-1.2.0-cp36-cp36m-manylinux1_i686.whl", hash = "sha256:efcf3397ae1e3c3a4a0a0636542bcad5adad3b1dd3e8e629d0b6e201347176c8"}, @@ -514,8 +757,8 @@ kiwisolver = [ {file = "kiwisolver-1.2.0.tar.gz", hash = "sha256:247800260cd38160c362d211dcaf4ed0f7816afb5efe56544748b21d6ad6d17f"}, ] markdown = [ - {file = "Markdown-3.2.1-py2.py3-none-any.whl", hash = "sha256:e4795399163109457d4c5af2183fbe6b60326c17cfdf25ce6e7474c6624f725d"}, - {file = "Markdown-3.2.1.tar.gz", hash = "sha256:90fee683eeabe1a92e149f7ba74e5ccdc81cd397bd6c516d93a8da0ef90b6902"}, + {file = "Markdown-3.2.2-py3-none-any.whl", hash = "sha256:c467cd6233885534bf0fe96e62e3cf46cfc1605112356c4f9981512b8174de59"}, + {file = "Markdown-3.2.2.tar.gz", hash = "sha256:1fafe3f1ecabfb514a5285fca634a53c1b32a81cb0feb154264d55bf2ff22c17"}, ] matplotlib = [ {file = "matplotlib-3.2.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:e06304686209331f99640642dee08781a9d55c6e32abb45ed54f021f46ccae47"}, @@ -533,6 +776,10 @@ matplotlib = [ {file = "matplotlib-3.2.1-pp373-pypy36_pp73-win32.whl", hash = "sha256:7a9baefad265907c6f0b037c8c35a10cf437f7708c27415a5513cf09ac6d6ddd"}, {file = "matplotlib-3.2.1.tar.gz", hash = "sha256:ffe2f9cdcea1086fc414e82f42271ecf1976700b8edd16ca9d376189c6d93aee"}, ] +networkx = [ + {file = "networkx-2.4-py3-none-any.whl", hash = "sha256:cdfbf698749a5014bf2ed9db4a07a5295df1d3a53bf80bf3cbd61edf9df05fa1"}, + {file = "networkx-2.4.tar.gz", hash = "sha256:f8f4ff0b6f96e4f9b16af6b84622597b5334bf9cae8cf9b2e42e7985d5c95c64"}, +] numpy = [ {file = "numpy-1.18.4-cp35-cp35m-macosx_10_9_intel.whl", hash = "sha256:efdba339fffb0e80fcc19524e4fdbda2e2b5772ea46720c44eaac28096d60720"}, {file = "numpy-1.18.4-cp35-cp35m-manylinux1_i686.whl", hash = "sha256:2b573fcf6f9863ce746e4ad00ac18a948978bb3781cffa4305134d31801f3e26"}, @@ -608,25 +855,22 @@ pillow = [ {file = "Pillow-7.1.2.tar.gz", hash = "sha256:a0b49960110bc6ff5fead46013bcb8825d101026d466f3a4de3476defe0fb0dd"}, ] protobuf = [ - {file = "protobuf-3.11.3-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:ef2c2e56aaf9ee914d3dccc3408d42661aaf7d9bb78eaa8f17b2e6282f214481"}, - {file = "protobuf-3.11.3-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:dd9aa4401c36785ea1b6fff0552c674bdd1b641319cb07ed1fe2392388e9b0d7"}, - {file = "protobuf-3.11.3-cp35-cp35m-macosx_10_9_intel.whl", hash = "sha256:310a7aca6e7f257510d0c750364774034272538d51796ca31d42c3925d12a52a"}, - {file = "protobuf-3.11.3-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:e512b7f3a4dd780f59f1bf22c302740e27b10b5c97e858a6061772668cd6f961"}, - {file = "protobuf-3.11.3-cp35-cp35m-win32.whl", hash = "sha256:fdfb6ad138dbbf92b5dbea3576d7c8ba7463173f7d2cb0ca1bd336ec88ddbd80"}, - {file = "protobuf-3.11.3-cp35-cp35m-win_amd64.whl", hash = "sha256:e2f8a75261c26b2f5f3442b0525d50fd79a71aeca04b5ec270fc123536188306"}, - {file = "protobuf-3.11.3-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:c40973a0aee65422d8cb4e7d7cbded95dfeee0199caab54d5ab25b63bce8135a"}, - {file = "protobuf-3.11.3-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:adf0e4d57b33881d0c63bb11e7f9038f98ee0c3e334c221f0858f826e8fb0151"}, - {file = "protobuf-3.11.3-cp36-cp36m-win32.whl", hash = "sha256:0bae429443cc4748be2aadfdaf9633297cfaeb24a9a02d0ab15849175ce90fab"}, - {file = "protobuf-3.11.3-cp36-cp36m-win_amd64.whl", hash = "sha256:e11df1ac6905e81b815ab6fd518e79be0a58b5dc427a2cf7208980f30694b956"}, - {file = "protobuf-3.11.3-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:7774bbbaac81d3ba86de646c39f154afc8156717972bf0450c9dbfa1dc8dbea2"}, - {file = "protobuf-3.11.3-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:8eb9c93798b904f141d9de36a0ba9f9b73cc382869e67c9e642c0aba53b0fc07"}, - {file = "protobuf-3.11.3-cp37-cp37m-win32.whl", hash = "sha256:fac513a9dc2a74b99abd2e17109b53945e364649ca03d9f7a0b96aa8d1807d0a"}, - {file = "protobuf-3.11.3-cp37-cp37m-win_amd64.whl", hash = "sha256:82d7ac987715d8d1eb4068bf997f3053468e0ce0287e2729c30601feb6602fee"}, - {file = "protobuf-3.11.3-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:73152776dc75f335c476d11d52ec6f0f6925774802cd48d6189f4d5d7fe753f4"}, - {file = "protobuf-3.11.3-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:52e586072612c1eec18e1174f8e3bb19d08f075fc2e3f91d3b16c919078469d0"}, - {file = "protobuf-3.11.3-py2.7.egg", hash = "sha256:2affcaba328c4662f3bc3c0e9576ea107906b2c2b6422344cdad961734ff6b93"}, - {file = "protobuf-3.11.3-py2.py3-none-any.whl", hash = "sha256:24e3b6ad259544d717902777b33966a1a069208c885576254c112663e6a5bb0f"}, - {file = "protobuf-3.11.3.tar.gz", hash = "sha256:c77c974d1dadf246d789f6dad1c24426137c9091e930dbf50e0a29c1fcf00b1f"}, + {file = "protobuf-3.12.0-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:bb1aced9dcebc46f0b320f24222cc8ffdfd2e47d2bafd4d2e5913cc6f7e3fc98"}, + {file = "protobuf-3.12.0-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:ccce142ebcfbc35643a5012cf398497eb18e8d021333cced4d5401f034a8cef5"}, + {file = "protobuf-3.12.0-cp35-cp35m-macosx_10_9_intel.whl", hash = "sha256:a7532d971e4ab2019a9f6aa224b209756b6b9e702940ca85a4b1ed1d03f45396"}, + {file = "protobuf-3.12.0-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:eab18765eb5c7bad1b2de7ae3774192b46e1873011682e36bcd70ccf75f2748a"}, + {file = "protobuf-3.12.0-cp35-cp35m-win32.whl", hash = "sha256:61364bcd2d85277ab6155bb7c5267e6a64786a919f1a991e29eb536aa5330a3d"}, + {file = "protobuf-3.12.0-cp35-cp35m-win_amd64.whl", hash = "sha256:0d69d76b00d0eb5124cb33a34a793383a5bbbf9ac3e633207c09988717c5da85"}, + {file = "protobuf-3.12.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:95f035bbafec7dbaa0f1c72eda8108b763c1671fcb6e577e93da2d52eb47fbcf"}, + {file = "protobuf-3.12.0-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:b4e8ecb1eb3d011f0ccc13f8bb0a2d481aa05b733e6e22e9d46a3f61dbbef0de"}, + {file = "protobuf-3.12.0-cp36-cp36m-win32.whl", hash = "sha256:9d6a517ce33cbdc64b52a17c56ce17b0b20679c945ed7420e7c6bc6686ff0494"}, + {file = "protobuf-3.12.0-cp36-cp36m-win_amd64.whl", hash = "sha256:1c55277377dd35e508e9d86c67a545f6d8d242d792af487678eeb75c07974ee2"}, + {file = "protobuf-3.12.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:9593a6cdfc491f2caf62adb1c03170e9e8748d0a69faa2b3970e39a92fbd05a2"}, + {file = "protobuf-3.12.0-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:47a541ac44f2dcc8d49b615bcf3ed7ba4f33af9791118cecc3d17815fab652d9"}, + {file = "protobuf-3.12.0-cp37-cp37m-win32.whl", hash = "sha256:d538eecc0b80accfb73c8167f39aaa167a5a50f31b1295244578c8eff8e9d602"}, + {file = "protobuf-3.12.0-cp37-cp37m-win_amd64.whl", hash = "sha256:00c2c276aca3af220d422e6a8625b1f5399c821c9b6f1c83e8a535aa8f48cc6c"}, + {file = "protobuf-3.12.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:35bc1b96241b8ea66dbf386547ef2e042d73dcc0bf4b63566e3ef68722bb24d1"}, + {file = "protobuf-3.12.0-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:7aaa820d629f8a196763dd5ba21fd272fa038f775a845a52e21fa67862abcd35"}, ] pyasn1 = [ {file = "pyasn1-0.4.8-py2.4.egg", hash = "sha256:fec3e9d8e36808a28efb59b489e4528c10ad0f480e57dcc32b4de5c9d8c9fdf3"}, @@ -658,14 +902,53 @@ pyasn1-modules = [ {file = "pyasn1_modules-0.2.8-py3.6.egg", hash = "sha256:cbac4bc38d117f2a49aeedec4407d23e8866ea4ac27ff2cf7fb3e5b570df19e0"}, {file = "pyasn1_modules-0.2.8-py3.7.egg", hash = "sha256:c29a5e5cc7a3f05926aff34e097e84f8589cd790ce0ed41b67aed6857b26aafd"}, ] +pycollada = [ + {file = "pycollada-0.7.1.tar.gz", hash = "sha256:d2eb5bc70c474af16223f8eeb83757d8a71e4c97d0c241cd1ef371ef36e5e4e6"}, +] +pyglet = [ + {file = "pyglet-1.5.5-py3-none-any.whl", hash = "sha256:9695fe73335246a13385c12b21d6562657ed62b15892d43660fa3207f0f515b9"}, + {file = "pyglet-1.5.5.zip", hash = "sha256:14f3f1c68c70aa101ee4ee91f122ec8ff41ebc30885a95f733ecbbc3542e4d70"}, +] +pyopengl = [ + {file = "PyOpenGL-3.1.0.tar.gz", hash = "sha256:9b47c5c3a094fa518ca88aeed35ae75834d53e4285512c61879f67a48c94ddaf"}, + {file = "PyOpenGL-3.1.0.win32.exe", hash = "sha256:5b3a14a4e4c87cf25ca41bc5878583df0e434624b13fcc55d1a672f79ad1b76f"}, + {file = "PyOpenGL-3.1.0.zip", hash = "sha256:efa4e39a49b906ccbe66758812ca81ced13a6f26931ab2ba2dba2750c016c0d0"}, +] pyparsing = [ {file = "pyparsing-2.4.7-py2.py3-none-any.whl", hash = "sha256:ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b"}, {file = "pyparsing-2.4.7.tar.gz", hash = "sha256:c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1"}, ] +pyrender = [ + {file = "pyrender-0.1.40-py3-none-any.whl", hash = "sha256:f750d23b2abb40b25d3ee776e567b952e4e134541195bc1dfca2159aa157bd54"}, + {file = "pyrender-0.1.40.tar.gz", hash = "sha256:4012dba55c317c3f991ce8658a6a94ea9acc9a0777ed52f24b2d98816cf57220"}, +] python-dateutil = [ {file = "python-dateutil-2.8.1.tar.gz", hash = "sha256:73ebfe9dbf22e832286dafa60473e4cd239f8592f699aa5adaf10050e6e1823c"}, {file = "python_dateutil-2.8.1-py2.py3-none-any.whl", hash = "sha256:75bb3f31ea686f1197762692a9ee6a7550b59fc6ca3a1f4b5d7e32fb98e2da2a"}, ] +pywavelets = [ + {file = "PyWavelets-1.1.1-cp35-cp35m-macosx_10_6_intel.whl", hash = "sha256:35959c041ec014648575085a97b498eafbbaa824f86f6e4a59bfdef8a3fe6308"}, + {file = "PyWavelets-1.1.1-cp35-cp35m-manylinux1_i686.whl", hash = "sha256:55e39ec848ceec13c9fa1598253ae9dd5c31d09dfd48059462860d2b908fb224"}, + {file = "PyWavelets-1.1.1-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:c06d2e340c7bf8b9ec71da2284beab8519a3908eab031f4ea126e8ccfc3fd567"}, + {file = "PyWavelets-1.1.1-cp35-cp35m-win32.whl", hash = "sha256:be105382961745f88d8196bba5a69ee2c4455d87ad2a2e5d1eed6bd7fda4d3fd"}, + {file = "PyWavelets-1.1.1-cp35-cp35m-win_amd64.whl", hash = "sha256:076ca8907001fdfe4205484f719d12b4a0262dfe6652fa1cfc3c5c362d14dc84"}, + {file = "PyWavelets-1.1.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:7947e51ca05489b85928af52a34fe67022ab5b81d4ae32a4109a99e883a0635e"}, + {file = "PyWavelets-1.1.1-cp36-cp36m-manylinux1_i686.whl", hash = "sha256:9e2528823ccf5a0a1d23262dfefe5034dce89cd84e4e124dc553dfcdf63ebb92"}, + {file = "PyWavelets-1.1.1-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:80b924edbc012ded8aa8b91cb2fd6207fb1a9a3a377beb4049b8a07445cec6f0"}, + {file = "PyWavelets-1.1.1-cp36-cp36m-win32.whl", hash = "sha256:d510aef84d9852653d079c84f2f81a82d5d09815e625f35c95714e7364570ad4"}, + {file = "PyWavelets-1.1.1-cp36-cp36m-win_amd64.whl", hash = "sha256:889d4c5c5205a9c90118c1980df526857929841df33e4cd1ff1eff77c6817a65"}, + {file = "PyWavelets-1.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:68b5c33741d26c827074b3d8f0251de1c3019bb9567b8d303eb093c822ce28f1"}, + {file = "PyWavelets-1.1.1-cp37-cp37m-manylinux1_i686.whl", hash = "sha256:18a51b3f9416a2ae6e9a35c4af32cf520dd7895f2b69714f4aa2f4342fca47f9"}, + {file = "PyWavelets-1.1.1-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:cfe79844526dd92e3ecc9490b5031fca5f8ab607e1e858feba232b1b788ff0ea"}, + {file = "PyWavelets-1.1.1-cp37-cp37m-win32.whl", hash = "sha256:720dbcdd3d91c6dfead79c80bf8b00a1d8aa4e5d551dc528c6d5151e4efc3403"}, + {file = "PyWavelets-1.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:bc5e87b72371da87c9bebc68e54882aada9c3114e640de180f62d5da95749cd3"}, + {file = "PyWavelets-1.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:98b2669c5af842a70cfab33a7043fcb5e7535a690a00cd251b44c9be0be418e5"}, + {file = "PyWavelets-1.1.1-cp38-cp38-manylinux1_i686.whl", hash = "sha256:e02a0558e0c2ac8b8bbe6a6ac18c136767ec56b96a321e0dfde2173adfa5a504"}, + {file = "PyWavelets-1.1.1-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:6162dc0ae04669ea04b4b51420777b9ea2d30b0a9d02901b2a3b4d61d159c2e9"}, + {file = "PyWavelets-1.1.1-cp38-cp38-win32.whl", hash = "sha256:79f5b54f9dc353e5ee47f0c3f02bebd2c899d49780633aa771fed43fa20b3149"}, + {file = "PyWavelets-1.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:935ff247b8b78bdf77647fee962b1cc208c51a7b229db30b9ba5f6da3e675178"}, + {file = "PyWavelets-1.1.1.tar.gz", hash = "sha256:1a64b40f6acb4ffbaccce0545d7fc641744f95351f62e4c6aaa40549326008c9"}, +] pyyaml = [ {file = "PyYAML-5.3.1-cp27-cp27m-win32.whl", hash = "sha256:74809a57b329d6cc0fdccee6318f44b9b8649961fa73144a98735b0aaf029f1f"}, {file = "PyYAML-5.3.1-cp27-cp27m-win_amd64.whl", hash = "sha256:240097ff019d7c70a4922b6869d8a86407758333f02203e0fc6ff79c5dcede76"}, @@ -692,6 +975,44 @@ rsa = [ {file = "rsa-4.0-py2.py3-none-any.whl", hash = "sha256:14ba45700ff1ec9eeb206a2ce76b32814958a98e372006c8fb76ba820211be66"}, {file = "rsa-4.0.tar.gz", hash = "sha256:1a836406405730121ae9823e19c6e806c62bbad73f890574fff50efa4122c487"}, ] +scikit-image = [ + {file = "scikit-image-0.17.2.tar.gz", hash = "sha256:bd954c0588f0f7e81d9763dc95e06950e68247d540476e06cb77bcbcd8c2d8b3"}, + {file = "scikit_image-0.17.2-cp36-cp36m-macosx_10_13_x86_64.whl", hash = "sha256:11eec2e65cd4cd6487fe1089aa3538dbe25525aec7a36f5a0f14145df0163ce7"}, + {file = "scikit_image-0.17.2-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:c5c277704b12e702e34d1f7b7a04d5ee8418735f535d269c74c02c6c9f8abee2"}, + {file = "scikit_image-0.17.2-cp36-cp36m-win32.whl", hash = "sha256:1fda9109a19dc9d7a4ac152d1fc226fed7282ad186a099f14c0aa9151f0c758e"}, + {file = "scikit_image-0.17.2-cp36-cp36m-win_amd64.whl", hash = "sha256:86a834f9a4d30201c0803a48a25364fe8f93f9feb3c58f2c483d3ce0a3e5fe4a"}, + {file = "scikit_image-0.17.2-cp37-cp37m-macosx_10_13_x86_64.whl", hash = "sha256:87ca5168c6fc36b7a298a1db2d185a8298f549854342020f282f747a4e4ddce9"}, + {file = "scikit_image-0.17.2-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:e99fa7514320011b250a21ab855fdd61ddcc05d3c77ec9e8f13edcc15d3296b5"}, + {file = "scikit_image-0.17.2-cp37-cp37m-win32.whl", hash = "sha256:ee3db438b5b9f8716a91ab26a61377a8a63356b186706f5b979822cc7241006d"}, + {file = "scikit_image-0.17.2-cp37-cp37m-win_amd64.whl", hash = "sha256:6b65a103edbc34b22640daf3b084dc9e470c358d3298c10aa9e3b424dcc02db6"}, + {file = "scikit_image-0.17.2-cp38-cp38-macosx_10_13_x86_64.whl", hash = "sha256:c0876e562991b0babff989ff4d00f35067a2ddef82e5fdd895862555ffbaec25"}, + {file = "scikit_image-0.17.2-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:178210582cc62a5b25c633966658f1f2598615f9c3f27f36cf45055d2a74b401"}, + {file = "scikit_image-0.17.2-cp38-cp38-win32.whl", hash = "sha256:7bedd3881ca4fea657a894815bcd5e5bf80944c26274f6b6417bb770c3f4f8e6"}, + {file = "scikit_image-0.17.2-cp38-cp38-win_amd64.whl", hash = "sha256:113bcacdfc839854f527a166a71768708328208e7b66e491050d6a57fa6727c7"}, +] +scipy = [ + {file = "scipy-1.4.1-cp35-cp35m-macosx_10_6_intel.whl", hash = "sha256:c5cac0c0387272ee0e789e94a570ac51deb01c796b37fb2aad1fb13f85e2f97d"}, + {file = "scipy-1.4.1-cp35-cp35m-manylinux1_i686.whl", hash = "sha256:a144811318853a23d32a07bc7fd5561ff0cac5da643d96ed94a4ffe967d89672"}, + {file = "scipy-1.4.1-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:71eb180f22c49066f25d6df16f8709f215723317cc951d99e54dc88020ea57be"}, + {file = "scipy-1.4.1-cp35-cp35m-win32.whl", hash = "sha256:770254a280d741dd3436919d47e35712fb081a6ff8bafc0f319382b954b77802"}, + {file = "scipy-1.4.1-cp35-cp35m-win_amd64.whl", hash = "sha256:a1aae70d52d0b074d8121333bc807a485f9f1e6a69742010b33780df2e60cfe0"}, + {file = "scipy-1.4.1-cp36-cp36m-macosx_10_6_intel.whl", hash = "sha256:bb517872058a1f087c4528e7429b4a44533a902644987e7b2fe35ecc223bc408"}, + {file = "scipy-1.4.1-cp36-cp36m-manylinux1_i686.whl", hash = "sha256:dba8306f6da99e37ea08c08fef6e274b5bf8567bb094d1dbe86a20e532aca088"}, + {file = "scipy-1.4.1-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:386086e2972ed2db17cebf88610aab7d7f6e2c0ca30042dc9a89cf18dcc363fa"}, + {file = "scipy-1.4.1-cp36-cp36m-win32.whl", hash = "sha256:8d3bc3993b8e4be7eade6dcc6fd59a412d96d3a33fa42b0fa45dc9e24495ede9"}, + {file = "scipy-1.4.1-cp36-cp36m-win_amd64.whl", hash = "sha256:dc60bb302f48acf6da8ca4444cfa17d52c63c5415302a9ee77b3b21618090521"}, + {file = "scipy-1.4.1-cp37-cp37m-macosx_10_6_intel.whl", hash = "sha256:787cc50cab3020a865640aba3485e9fbd161d4d3b0d03a967df1a2881320512d"}, + {file = "scipy-1.4.1-cp37-cp37m-manylinux1_i686.whl", hash = "sha256:0902a620a381f101e184a958459b36d3ee50f5effd186db76e131cbefcbb96f7"}, + {file = "scipy-1.4.1-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:00af72998a46c25bdb5824d2b729e7dabec0c765f9deb0b504f928591f5ff9d4"}, + {file = "scipy-1.4.1-cp37-cp37m-win32.whl", hash = "sha256:9508a7c628a165c2c835f2497837bf6ac80eb25291055f56c129df3c943cbaf8"}, + {file = "scipy-1.4.1-cp37-cp37m-win_amd64.whl", hash = "sha256:a2d6df9eb074af7f08866598e4ef068a2b310d98f87dc23bd1b90ec7bdcec802"}, + {file = "scipy-1.4.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:3092857f36b690a321a662fe5496cb816a7f4eecd875e1d36793d92d3f884073"}, + {file = "scipy-1.4.1-cp38-cp38-manylinux1_i686.whl", hash = "sha256:8a07760d5c7f3a92e440ad3aedcc98891e915ce857664282ae3c0220f3301eb6"}, + {file = "scipy-1.4.1-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:1e3190466d669d658233e8a583b854f6386dd62d655539b77b3fa25bfb2abb70"}, + {file = "scipy-1.4.1-cp38-cp38-win32.whl", hash = "sha256:cc971a82ea1170e677443108703a2ec9ff0f70752258d0e9f5433d00dda01f59"}, + {file = "scipy-1.4.1-cp38-cp38-win_amd64.whl", hash = "sha256:2cce3f9847a1a51019e8c5b47620da93950e58ebc611f13e0d11f4980ca5fecb"}, + {file = "scipy-1.4.1.tar.gz", hash = "sha256:dee1bbf3a6c8f73b6b218cb28eed8dd13347ea2f87d572ce19b289d6fd3fbc59"}, +] six = [ {file = "six-1.14.0-py2.py3-none-any.whl", hash = "sha256:8f3cd2e254d8f793e7f3d6d9df77b92252b52637291d0f0da013c76ea2724b6c"}, {file = "six-1.14.0.tar.gz", hash = "sha256:236bdbdce46e6e6a3d61a337c0f8b763ca1e8717c03b369e87a7ec7ce1319c0a"}, @@ -703,6 +1024,10 @@ tensorboard-plugin-wit = [ {file = "tensorboard_plugin_wit-1.6.0.post3-py2-none-any.whl", hash = "sha256:243f117d117f9e81a21dc64b602b2bcb256ca5ba038867b96022d02271b17106"}, {file = "tensorboard_plugin_wit-1.6.0.post3-py3-none-any.whl", hash = "sha256:1fdf4ac343f1665453205aef8bb227b0204893bb5ffb792d2ed4509b1daf3d4f"}, ] +tifffile = [ + {file = "tifffile-2020.5.11-py3-none-any.whl", hash = "sha256:2e110ea3a6381df534261a85091490a5678faa4535aa14cc11b8ea8379dcbf01"}, + {file = "tifffile-2020.5.11.tar.gz", hash = "sha256:abfce379f2b4b97759796c1489ea0e73c349fc71bf09bea2a5d076cbe7cfd4eb"}, +] torch = [ {file = "torch-1.4.0-cp27-cp27m-manylinux1_x86_64.whl", hash = "sha256:271d4d1e44df6ed57c530f8849b028447c62b8a19b8e8740dd9baa56e7f682c1"}, {file = "torch-1.4.0-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:6f2fd9eb8c7eaf38a982ab266dbbfba0f29fb643bc74e677d045d6f2595e4692"}, @@ -716,7 +1041,6 @@ torch = [ {file = "torch-1.4.0-cp38-cp38-manylinux1_x86_64.whl", hash = "sha256:504915c6bc6051ba6a4c2a43c446463dff04411e352f1e26fe13debeae431778"}, {file = "torch-1.4.0-cp38-none-macosx_10_9_x86_64.whl", hash = "sha256:d7b34a78f021935ad727a3bede56a8a8d4fda0b0272314a04c5f6890bbe7bb29"}, ] -torchsearchsorted = [] torchvision = [ {file = "torchvision-0.5.0-cp27-cp27m-macosx_10_7_x86_64.whl", hash = "sha256:35e9483858cf8a38debc647c74741605c5c12448d314aa96961082380aadf7e5"}, {file = "torchvision-0.5.0-cp27-cp27m-manylinux1_x86_64.whl", hash = "sha256:323500d349d8d91ce2662de41212e8eb1845c68dbf5d4f215ca1e94c7f20723b"}, @@ -738,6 +1062,10 @@ tqdm = [ {file = "tqdm-4.46.0-py2.py3-none-any.whl", hash = "sha256:acdafb20f51637ca3954150d0405ff1a7edde0ff19e38fb99a80a66210d2a28f"}, {file = "tqdm-4.46.0.tar.gz", hash = "sha256:4733c4a10d0f2a4d098d801464bdaf5240c7dadd2a7fde4ee93b0a0efd9fb25e"}, ] +trimesh = [ + {file = "trimesh-3.6.39-py3-none-any.whl", hash = "sha256:3afb0848c97ce044e02f7e58ce7dc9ae7e75540fabfcc530cec3efdabdba9399"}, + {file = "trimesh-3.6.39.tar.gz", hash = "sha256:13362c23e97050e64b36aa32a8c354234e42d93bc908d846602916ad9b7e6838"}, +] urllib3 = [ {file = "urllib3-1.25.9-py2.py3-none-any.whl", hash = "sha256:88206b0eb87e6d677d424843ac5209e3fb9d0190d0ee169599165ec25e9d9115"}, {file = "urllib3-1.25.9.tar.gz", hash = "sha256:3018294ebefce6572a474f0604c2021e33b3fd8006ecd11d62107a5d2a963527"}, @@ -750,3 +1078,7 @@ wheel = [ {file = "wheel-0.34.2-py2.py3-none-any.whl", hash = "sha256:df277cb51e61359aba502208d680f90c0493adec6f0e848af94948778aed386e"}, {file = "wheel-0.34.2.tar.gz", hash = "sha256:8788e9155fe14f54164c1b9eb0a319d98ef02c160725587ad60f14ddc57b6f96"}, ] +zipp = [ + {file = "zipp-3.1.0-py3-none-any.whl", hash = "sha256:aa36550ff0c0b7ef7fa639055d797116ee891440eac1a56f378e2d3179e0320b"}, + {file = "zipp-3.1.0.tar.gz", hash = "sha256:c599e4d75c98f6798c509911d08a22e6c021d074469042177c8c86fb92eefd96"}, +] diff --git a/pyproject.toml b/pyproject.toml index 9dbae1e..b091849 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,8 +1,8 @@ [tool.poetry] -name = "nerfmeshes" +name = "cchiv-nerf" version = "0.1.0" description = "A mesh reconstruction tool build around Neural Radiance Fields" -authors = ["Benedikt Wiberg "] +authors = ["Cristian Chivrga "] license = "MIT" [tool.poetry.dependencies] @@ -15,8 +15,11 @@ torchvision = "^0.5.0" tqdm = "^4.46.0" opencv-python-headless = "^4.2.0" matplotlib = "^3.2.1" -torchsearchsorted = { git = "https://github.com/aliutkus/torchsearchsorted"} -torch = "1.4.0" +trimesh = "^3.6.38" +pyrender = "^0.1.40" +pycollada = "^0.7.1" +scipy = "^1.4.1" +scikit-image = "^0.17.2" [tool.poetry.dev-dependencies] diff --git a/src/nerf/cache_dataset.py b/src/cache_dataset.py similarity index 100% rename from src/nerf/cache_dataset.py rename to src/cache_dataset.py diff --git a/src/nerf/config/default.yml b/src/config/default.yml similarity index 100% rename from src/nerf/config/default.yml rename to src/config/default.yml diff --git a/src/nerf/config/fern.yml b/src/config/fern.yml similarity index 100% rename from src/nerf/config/fern.yml rename to src/config/fern.yml diff --git a/src/nerf/config/lego.yml b/src/config/lego.yml similarity index 100% rename from src/nerf/config/lego.yml rename to src/config/lego.yml diff --git a/src/nerf/config/llff.yml b/src/config/llff.yml similarity index 100% rename from src/nerf/config/llff.yml rename to src/config/llff.yml diff --git a/src/nerf/config/tiny.yaml b/src/config/tiny.yaml similarity index 100% rename from src/nerf/config/tiny.yaml rename to src/config/tiny.yaml diff --git a/src/nerf/eval_nerf.py b/src/eval_nerf.py similarity index 100% rename from src/nerf/eval_nerf.py rename to src/eval_nerf.py diff --git a/src/nerf/lieutils.py b/src/lieutils.py similarity index 100% rename from src/nerf/lieutils.py rename to src/lieutils.py diff --git a/src/mesh_nerf.py b/src/mesh_nerf.py new file mode 100644 index 0000000..2dfff06 --- /dev/null +++ b/src/mesh_nerf.py @@ -0,0 +1,307 @@ +import argparse +import os +import time +import numpy as np +import torch +import torchvision +import yaml + +from pathlib import Path +from nerf import run_network +from skimage import measure +from scipy.spatial import KDTree +from tqdm import tqdm + +from nerf import get_minibatches + +from nerf import ( + CfgNode, + load_blender_data, + load_llff_data, + models, + get_embedding_function, + predict_and_render_radiance, + volume_render_radiance_field +) + +def export_obj(vertices, triangles, diffuse, normals, filename): + """ + Exports a mesh in the (.obj) format. + """ + + with open(filename, 'w') as fh: + + for index, v in enumerate(vertices): + fh.write("v {} {} {} {} {} {}\n".format(*v, *diffuse[index])) + + for n in normals: + fh.write("vn {} {} {}\n".format(*n)) + + for f in triangles: + fh.write("f") + for index in f: + fh.write(" {}//{}".format(index + 1, index + 1)) + + fh.write("\n") + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument( + "--config", type = str, required = True, help = "Path to (.yml) config file." + ) + parser.add_argument( + "--base-dir", + type = str, + required = False, + help = "Override the default base dir.", + ) + parser.add_argument( + "--checkpoint", + type = str, + required = True, + help = "Checkpoint / pre-trained model to evaluate.", + ) + parser.add_argument( + "--save-dir", type = str, help = "Save mesh to this directory, if specified." + ) + + parser.add_argument('--cache-mesh', dest = 'cache_mesh', action = 'store_true') + parser.add_argument('--no-cache-mesh', dest = 'cache_mesh', action = 'store_false') + parser.set_defaults(cache_mesh = True) + + configargs = parser.parse_args() + + # Read config file. + cfg, model_name = None, None + with open(configargs.config, "r") as f: + cfg_dict = yaml.load(f, Loader = yaml.FullLoader) + cfg, model_name = CfgNode(cfg_dict), Path(f.name).stem + + # Device on which to run. + device = "cpu" if not torch.cuda.is_available() else "cuda" + + encode_position_fn = get_embedding_function( + num_encoding_functions = cfg.models.coarse.num_encoding_fn_xyz, + include_input = cfg.models.coarse.include_input_xyz, + log_sampling = cfg.models.coarse.log_sampling_xyz, + ) + + encode_direction_fn = None + if cfg.models.coarse.use_viewdirs: + encode_direction_fn = get_embedding_function( + num_encoding_functions = cfg.models.coarse.num_encoding_fn_dir, + include_input = cfg.models.coarse.include_input_dir, + log_sampling = cfg.models.coarse.log_sampling_dir, + ) + + # Initialize a coarse resolution model. + model_coarse = getattr(models, cfg.models.coarse.type)( + num_encoding_fn_xyz = cfg.models.coarse.num_encoding_fn_xyz, + num_encoding_fn_dir = cfg.models.coarse.num_encoding_fn_dir, + include_input_xyz = cfg.models.coarse.include_input_xyz, + include_input_dir = cfg.models.coarse.include_input_dir, + use_viewdirs = cfg.models.coarse.use_viewdirs, + ).to(device) + + # If a fine-resolution model is specified, initialize it. + model_fine = None + if hasattr(cfg.models, "fine"): + model_fine = getattr(models, cfg.models.fine.type)( + num_encoding_fn_xyz = cfg.models.fine.num_encoding_fn_xyz, + num_encoding_fn_dir = cfg.models.fine.num_encoding_fn_dir, + include_input_xyz = cfg.models.fine.include_input_xyz, + include_input_dir = cfg.models.fine.include_input_dir, + use_viewdirs = cfg.models.fine.use_viewdirs, + ).to(device) + + checkpoint = torch.load(configargs.checkpoint) + model_coarse.load_state_dict(checkpoint["model_coarse_state_dict"]) + if checkpoint["model_fine_state_dict"]: + try: + model_fine.load_state_dict(checkpoint["model_fine_state_dict"]) + except: + print( + "The checkpoint has a fine-level model, but it could " + "not be loaded (possibly due to a mismatched config file." + ) + + model_coarse.eval() + if model_fine: + model_fine.eval() + + # Mesh Extraction + N = 128 + iso_value = 32 + batch_size = 1024 + density_samples_count = 6 + chunk = int(density_samples_count / 2) + distance_length = 0.001 + distance_threshold = 0.001 + view_disparity = 0.2 + limit = 1.2 + t = np.linspace(-limit, limit, N) + sampling_method = 0 + adjust_normals = False + specific_view = False + plane_near = 0 + plane_far = 6 + + vertices, triangles, normals, diffuse = None, None, None, None + if configargs.cache_mesh: + query_pts = np.stack(np.meshgrid(t, t, t), -1).astype(np.float32) + pts = torch.from_numpy(query_pts) + dimension = pts.shape[-1] + + pts_flat = pts.reshape((-1, dimension)) + pts_flat_batch = pts_flat.reshape((-1, batch_size, dimension)) + + density = np.zeros((pts_flat.shape[0])) + for idx, batch in enumerate(tqdm(pts_flat_batch)): + batch = batch.cuda() + + embedded = encode_position_fn(batch) + if encode_direction_fn is not None: + embedded_dirs = encode_direction_fn(batch) + embedded = torch.cat((embedded, embedded_dirs), dim = -1) + + result_batch = model_fine(embedded) + + # Extracting the density + density[idx * batch_size: (idx + 1) * batch_size] = result_batch[..., 3].cpu().detach().numpy() + + # Create a 3D density grid + grid_alpha = density.reshape((N, N, N)) + + # Extracting iso-surface triangulated + vertices, triangles, normals, values = measure.marching_cubes(grid_alpha, iso_value) + vertices = np.ascontiguousarray(vertices) + normals = np.ascontiguousarray(normals) + + # Query directly without specific-views + if specific_view: + targets = torch.from_numpy(vertices) / N * 2 * limit - limit + targets = targets[:, [1, 0, 2]] + stride = 512 + diffuse = np.zeros((len(targets), 3)) + for idx in range(0, len(targets) // stride + 1): + offset1 = stride * idx + offset2 = np.minimum(stride * (idx + 1), len(vertices)) + batch = targets[offset1:offset2].to(device) + + embedded = encode_position_fn(batch) + if encode_direction_fn is not None: + embedded_dirs = encode_direction_fn(batch) + embedded = torch.cat((embedded, embedded_dirs), dim = -1) + + result_batch = model_fine(embedded) + + # Query the whole diffuse map + diffuse[offset1:offset2] = result_batch[..., :3].cpu().detach().numpy() + + if adjust_normals: + # Re-adjust normals based on NERF's density grid + # Create a density KDTree look-up table + tree = KDTree(pts_flat) if sampling_method == 0 else None + + # Create some density samples + density_samples = np.linspace(-distance_length, distance_length, density_samples_count)[:, np.newaxis] + + # Adjust normals with the assumption of having proper geometry + print("Adjusting normals") + for index, vertex in enumerate(tqdm(vertices)): + vertex_norm = vertex[[1, 0, 2]] / N * 2 * limit - limit + vertex_direction = normals[index][[1, 0, 2]] + + # Sample points across the ray direction (a.k.a normal) + samples = vertex_norm[np.newaxis, :].repeat(density_samples_count, 0) + \ + vertex_direction[np.newaxis, :].repeat(density_samples_count, 0) * density_samples + + def extract_cum_density(samples): + inliers_indices = None + if sampling_method == 0: + # Sample 1th nearest neighbor + distances, indices = tree.query(samples, 1) + + # Filter outliers + inliers_indices = indices[distances <= distance_threshold] + elif sampling_method == 1: + # Sample based on grid proximity + indices = (np.around((samples + limit) / 2 / limit * N) * N ** np.arange(2, -1, -1)).sum(1).astype(int) + + # Filtering exceeding boundaries + inliers_indices = indices[~(indices >= N ** 3)] + else: + # Sample based on re-computing the radiance field + indices = (np.around((samples + limit) / 2 / limit * N) * N ** np.arange(2, -1, -1)).sum(1).astype(int) + + # Filtering exceeding boundaries + inliers_indices = indices[~(indices >= N ** 3)] + + return density[inliers_indices].sum() + + # Extract densities + sample_density_1 = extract_cum_density(samples[:chunk]) + sample_density_2 = extract_cum_density(samples[chunk:]) + + # Re-direct the normal + if sample_density_1 < sample_density_2: + normals[index] *= (-1) + + np.save(os.path.join(configargs.save_dir, "mesh_cache.npy"), (vertices, triangles, normals)) + print("Saved successfully") + else: + vertices, triangles, normals = np.load(os.path.join(configargs.save_dir, "mesh_cache.npy"), allow_pickle = True) + + # Extracting the diffuse color + # Ray targets + targets = torch.from_numpy(vertices) / N * 2 * limit - limit + # Swap x-axis and y-axis + targets = targets[:, [1, 0, 2]] + + # Ray directions + directions = torch.from_numpy(normals) + + # Ray directions swapped based on Marching Cubes algorithm + directions = directions[:, [1, 0, 2]] + + # Ray origins + # ray_origins = length * directions + ray_origins = targets + view_disparity * directions + + # Ray directions + ray_directions_loose = targets - ray_origins + ray_directions = ray_directions_loose / ray_directions_loose.norm(dim = 1).unsqueeze(1) + + near = plane_near * torch.ones_like(ray_directions[..., :1]) + far = plane_far * torch.ones_like(ray_directions[..., :1]) + + # Generating ray batches + rays = torch.cat((ray_origins, ray_directions, near, far), dim = -1) + if cfg.nerf.use_viewdirs: + # Provide ray directions as input + view_dirs = ray_directions / ray_directions.norm(p = 2, dim = -1).unsqueeze(-1) + rays = torch.cat((rays, view_dirs.view((-1, 3))), dim = -1) + + ray_batches = get_minibatches(rays, chunksize = 2048) + + pred = [] + for ray_batch in ray_batches: + # move to appropriate device + ray_batch = ray_batch.to(device) + + _, _, _, diffuse, _, _ = predict_and_render_radiance(ray_batch, model_coarse, model_fine, cfg, + mode = "validation", + encode_position_fn = encode_position_fn, + encode_direction_fn = encode_direction_fn, + ) + + pred.append(diffuse.cpu().detach()) + + # Query the whole diffuse map + diffuse = torch.cat(pred, dim = 0).numpy() + + # Export model + export_obj(vertices, triangles, diffuse, normals, os.path.join(configargs.save_dir, f"{model_name}.obj")) + +if __name__ == "__main__": + main() diff --git a/src/nerf/nerf/__init__.py b/src/nerf/__init__.py similarity index 100% rename from src/nerf/nerf/__init__.py rename to src/nerf/__init__.py diff --git a/src/nerf/nerf/cfgnode.py b/src/nerf/cfgnode.py similarity index 100% rename from src/nerf/nerf/cfgnode.py rename to src/nerf/cfgnode.py diff --git a/src/nerf/nerf/load_blender.py b/src/nerf/load_blender.py similarity index 100% rename from src/nerf/nerf/load_blender.py rename to src/nerf/load_blender.py diff --git a/src/nerf/nerf/load_llff.py b/src/nerf/load_llff.py similarity index 100% rename from src/nerf/nerf/load_llff.py rename to src/nerf/load_llff.py diff --git a/src/nerf/nerf/metrics.py b/src/nerf/metrics.py similarity index 100% rename from src/nerf/nerf/metrics.py rename to src/nerf/metrics.py diff --git a/src/nerf/nerf/models.py b/src/nerf/models.py similarity index 100% rename from src/nerf/nerf/models.py rename to src/nerf/models.py diff --git a/src/nerf/nerf/nerf_helpers.py b/src/nerf/nerf_helpers.py similarity index 100% rename from src/nerf/nerf/nerf_helpers.py rename to src/nerf/nerf_helpers.py diff --git a/src/nerf/nerf/train_utils.py b/src/nerf/train_utils.py similarity index 100% rename from src/nerf/nerf/train_utils.py rename to src/nerf/train_utils.py diff --git a/src/nerf/nerf/volume_rendering_utils.py b/src/nerf/volume_rendering_utils.py similarity index 100% rename from src/nerf/nerf/volume_rendering_utils.py rename to src/nerf/volume_rendering_utils.py diff --git a/src/nerf/tiny_nerf.py b/src/tiny_nerf.py similarity index 100% rename from src/nerf/tiny_nerf.py rename to src/tiny_nerf.py diff --git a/src/nerf/train_nerf.py b/src/train_nerf.py similarity index 100% rename from src/nerf/train_nerf.py rename to src/train_nerf.py