Skip to content
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

File not found - *.cpp and File not found - *.c #1

Open
florinmatthew opened this issue Sep 3, 2017 · 13 comments
Open

File not found - *.cpp and File not found - *.c #1

florinmatthew opened this issue Sep 3, 2017 · 13 comments

Comments

@florinmatthew
Copy link

"File not found" running under Windows 10

@florinmatthew
Copy link
Author

More:
g++ -std=c++11 -Wall -Wextra -Wno-unknown-pragmas -O3 -ftree-vectorize -funroll-loops -o bin/film_grain_rendering_main -lpng -ltiff
process_begin: CreateProcess(NULL, g++ -std=c++11 -Wall -Wextra -Wno-unknown-pragmas -O3 -ftree-vectorize -funroll-loops -o bin/film_grain_rendering_main -lpng -ltiff, ...) failed.
make (e=2): The system cannot find the file specified.
make: *** [bin/film_grain_rendering_main] Error 2

@ghost
Copy link

ghost commented Apr 25, 2018

I'm also experiencing "missing" files, though I have no experience with coding so maybe I'm just doing something wrong.

C:\Users\User\Desktop\Film_grain_rendering_IPOL>make.exe
File not found - *.cpp
File not found - *.c
"===== Link bin/film_grain_rendering_main ====="
g++ -std=c++11 -Wall -Wextra -Wno-unknown-pragmas -O3 -ftree-vectorize -funroll-loops -o bin/film_grain_rendering_main -lpng -ltiff
process_begin: CreateProcess(NULL, g++ -std=c++11 -Wall -Wextra -Wno-unknown-pragmas -O3 -ftree-vectorize -funroll-loops -o bin/film_grain_rendering_main -lpng -ltiff, ...) failed.
make (e=2): The system cannot find the file specified.
make.exe: *** [bin/film_grain_rendering_main] Error 2

@alasdairnewson
Copy link
Owner

Hi there, sorry for these bugs, in fact this is a research code, so it was tested with a linux operating system. Apparently, the bugs are with windows. Can you tell me what you are using to compile the code ? As specified in the readme.txt, you need to compile the code with the makefile provided. If you do not know how makefiles work, I can discuss this directly with you rather than exchanging here.

Thanks !

@ghost
Copy link

ghost commented Apr 27, 2018 via email

@alasdairnewson
Copy link
Owner

alasdairnewson commented Apr 27, 2018

Hi ! Yes, compiling with windows can often be a pain, which is why many people use linux for this purpose. In linux, you just open a terminal and type 'make', and if you have the necessary libraries, everything is good, you get an executable.

What I would suggest is to install the 'cygwin' program, I think that is the best option.
https://www.cygwin.com/install.html

This imitates linux in windows. If you can do this, then you should be able to just go to the correct directory and simply type 'make'. You will have to install libpng and libtiff, but I can help you with that.

Let me know if you have correctly installed cygwin.

Otherwise I will try and find a windows installation to compile the code.

@ghost
Copy link

ghost commented Apr 27, 2018 via email

@alasdairnewson
Copy link
Owner

Hi ! Could you go to the root directory of the code (the directory where you decompressed the file), and type 'make' and tell me what happens ? I will be travelling this weekend so i might not be able to get back to you straight away !

@ghost
Copy link

ghost commented Apr 30, 2018

User@Box /cygdrive/d/users/film_grain_rendering_ipol - copy
$ make
===== Compile src/io_png.c =====
g++ -std=c++11 -Wall -Wextra -Wno-unknown-pragmas -O3 -ftree-vectorize -funroll-loops -Isrc -c src/io_png.c -o obj/io_png.o
In file included from src/io_png.c:46:0:
src/png.h:361:27: fatal error: pnglibconf.h: No such file or directory

                       ^

compilation terminated.
make: *** [makefile:48: obj/io_png.o] Error 1

As mentioned, the directories shown in that video do not exist within Visual Studios 2017. Not sure how else to obtain the file.

@alasdairnewson
Copy link
Owner

Hi again, ok, yes this means that the libpng (and libtiff) libraries are not installed. To install these in cygwin, apparently, you need to click again on the setup.exe file of cygwin, which will allow you to select certain packages:

https://cygwin.com/cygwin-ug-net/setup-net.html#setup-packages

This should install the packages, at which point you just need to do a 'make' in the code's root directory again, and it should be ok. You might have to restart cygwin after installing the packages.

@ghost
Copy link

ghost commented May 20, 2018

I decided to give it another go today, I managed to get the code compiled and working. However, is the program strictly limited to using Cygwin to operate it, or is it possible to execute it as its own entity in another window (like photoshop or lightroom, etc.)? Also a few more additional questions, now that I know how to install it. When I try to input a .TIF file, I'm prompted with "unable to read the input image". I tried to process a full resolution 4000x6000 16-bit .PNG image with it, and after roughly 20 minutes it had failed to write, aside from processing times (which I expect to be lengthy,) what is the max acceptable resolution (unless that's not quantifiable)? I tried a 400x600 16-bit (I know it says 8-bit gray but I thought I'd try) .PNG and it had written successfully and produced after 1 minute, though I'm stuck to using black and white and (edit: set it to 8-bit, I can now edit full resolution) low resolutions. I swear I recalled seeing something earlier that you could change the values from 0 to 1 to get color. I just can't remember where I had seen that amongst the files, or where to place it in the chain of commands (the example given, referred to below.)

bin/film_grain_rendering_main input.tiff output.png -r "0.1" -grainSigma "0.0" -filterSigma "0.8" -zoom "2.0" -algorithmID "0" -NmonteCarlo "100"

@alasdairnewson
Copy link
Owner

Hi ! I'm glad you got the code working ! Yes, for this version, you have to use it with a command line. There is another version which has a GUI, but you would have to have QT creator installed, which I imagine you do not have if you do not code very much. I would be interesting in developing a photoshop version at some point, but it always seemed too slow for that purpose, at the moment anyway.

I think that the TIF file problem may be a very stupid bug indeed ! I think that I check whether the file has the extension '.tiff', and if not the code does not consider it to be a tiff file ... so try just renaming it to .tiff :)

I would be interested to see the file you are talking about, and to check the bug out. Could you send it to me ? I will send you an email so you can write me directly. Yes, you should be able to get colour, it should do it automatically.

@alasdairnewson
Copy link
Owner

Sorry, rectification ! You have to set -color to 1 in the command line options ! Sorry, I didn't write that in the readme, I will rectify that !

@ghost
Copy link

ghost commented May 21, 2018 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants