quatrope / ois Goto Github PK
View Code? Open in Web Editor NEWOptimal Image Subtraction
License: MIT License
Optimal Image Subtraction
License: MIT License
Hello, I'm trying to install ois in PyCharm under windows10. Before installing ois, MSVC build tool was installed due to C++ 14.0 is required for astroalign package.
When begin to install ois, the error message shows "fatal error LNK1181: cannot open input file 'm.lib' ". I examined the LIBPATHs in error message to check whether there was a 'm.lib' file, of course this file doesn't exist.
So, is the 'm.lib' file very neccessary for ois? Is it safe to remove the line "libraries = ['m']" in setup.py like coreylynch/pyFM#18 ? Or, Is there somewhere I could find this lib file?
here is error message[I split them to make them easier to read by human :) ]
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.27.29110\bin\HostX86\x64\link.exe /nologo /INCREMENTAL:NO /LTCG /DLL /MANIFEST:EMBED,ID=2 /MANIFESTUAC:NO
/LIBPATH:C:\Users\zhou1\AppData\Local\Programs\Python\Python38\libs
/LIBPATH:C:\Users\zhou1\AppData\Local\Programs\Python\Python38\PCbuild\amd64
"/LIBPATH:C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.27.29110\lib\x64"
"/LIBPATH:C:\Program Files (x86)\Windows Kits\10\lib\10.0.18362.0\ucrt\x64"
"/LIBPATH:C:\Program Files (x86)\Windows Kits\10\lib\10.0.18362.0\um\x64" m.lib
/EXPORT:PyInit_varconv build\temp.win-amd64-3.8\Release\src/varconv.obj build\temp.win-amd64-3.8\Release\src/oistools.obj
/OUT:build\lib.win-amd64-3.8\varconv.cp38-win_amd64.pyd
/IMPLIB:build\temp.win-amd64-3.8\Release\src\varconv.cp38-win_amd64.lib
LINK : fatal error LNK1181: cannot open input file “m.lib”
error: command 'C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.27.29110\bin\HostX86\x64\link.exe' failed with exit status 1181
Write a general background test and have 1 call for each method.
I'm testing with grid = (1, 1) which doesn't test the slicing partition.
And add tests for newer Python versions.
ois.optimal_system(image=hdul.data, refimage=template, method="AdaptiveBramich", poly_degree=2)
exits with a segmentation fault when poly_degree
is not equal to 0.
We found that this is possibly because bkg_dof
is overflowing in src/oistools.c:build_matrix_system
.
We run several different poly_degrees, and the bkg_dof
is constantly equal to -INT_MAX
.
gdb frame files are attached.
ois2.gdb.txt
oispoly_degree3.gdb.txt
ois.gdb.txt
Separate C extension in functions that python calls and C functions that can be used independently.
The bot created this issue to inform you that pyup.io has been set up on this repo.
Once you have closed it, the bot will open pull requests for updates as soon as they are available.
prefix with underscore
Add pyproject.toml.
From Skyview or other image online repo
For adaptive kernel, return kernel
such that kernel(x, y)
gives the kernel at position (x, y).
This would also make eval_adpative_kernel
unnecessary.
Test with bkg_degree=None so background doesn't introduce errors.
Make asserts for all 4 returned values.
Compilation is different on MS Windows OS.
from his import subtract
"his" is a typo.
poly_degree
is snake case and the rest has no case.
Change poly_degree
-> polydegree
.
When trying to install via pip install ois
on MacOS 13.0 running Python 3.8.10 the following error is returned:
Using cached ois-0.2.tar.gz (11 kB)
Preparing metadata (setup.py) ... done
Requirement already satisfied: numpy>=1.6 in ./env/lib/python3.8/site-packages (from ois) (1.23.4)
Requirement already satisfied: scipy>=0.16 in ./env/lib/python3.8/site-packages (from ois) (1.9.3)
Installing collected packages: ois
DEPRECATION: ois is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at https://github.com/pypa/pip/issues/8559
Running setup.py install for ois ... error
error: subprocess-exited-with-error
× Running setup.py install for ois did not run successfully.
│ exit code: 1
╰─> [13 lines of output]
running install
running build
running build_py
creating build
creating build/lib.macosx-10.9-x86_64-3.8
copying ois.py -> build/lib.macosx-10.9-x86_64-3.8
running build_ext
building 'varconv' extension
creating build/temp.macosx-10.9-x86_64-3.8
creating build/temp.macosx-10.9-x86_64-3.8/src
gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/opt/anaconda3/include -arch x86_64 -I/opt/anaconda3/include -arch x86_64 -Isrc -I/Users/gabriel/Documents/GRB-SNe/GRBSNToolkit/env/lib/python3.8/site-packages/numpy/core/include -I/Users/gabriel/Documents/GRB-SNe/GRBSNToolkit/env/include -I/opt/anaconda3/include/python3.8 -c src/varconv.c -o build/temp.macosx-10.9-x86_64-3.8/src/varconv.o -std=c99
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
error: command 'gcc' failed with exit status 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> ois
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
A little math to explain the parameters.
Even for same complexity as Bramich
Move testing to tox.
Implement A&L "afterburner" decorrelation. Explained here: https://dmtn-021.lsst.io
center
is sometimes (x, y) and sometimes (row, column).
Change docstring.
Global warming comes from greenhouse effect gas emissions originated in modern civilization.
This needs to be stopped.
Add function to evaluate the adaptive kernel at a specified (x, y) on the image.
This is useful to have a sense of what the kernel look like in different parts of the image.
MIT License.
The final convolution leaves masked pixels untouched.
It should use unmasked pixels to calculate the convolution kernel but apply the convolution to all pixels regardless of mask.
astropy.convolution
provides convolution functions and kernels that offers improvements compared to the scipy scipy.ndimage
convolution routines, including:
Docs here.
The print statement in optimalkernelandbkg for kernels with an even side length should be an exception instead.
Find a better image (bigger) for testing. Current one (cameraman) is too small to have meaningful data when partitioned into grids.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.