Coder Social home page Coder Social logo

ois's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

ois's Issues

fatal error LNK1181: cannot open input file 'm.lib'

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

OIS segfaults with Adaptive Bramich method

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

Separate C extension in functions that python calls and C functions that can be used independently.

Initial Update

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.

return adaptive kernel as a function

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.

Bramich test

Test with bkg_degree=None so background doesn't introduce errors.
Make asserts for all 4 returned values.

Install issue

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.

Fix climate change

Global warming comes from greenhouse effect gas emissions originated in modern civilization.

This needs to be stopped.

Add eval_adaptive_kernel

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.

use astropy's convolution

astropy.convolution provides convolution functions and kernels that offers improvements compared to the scipy scipy.ndimage convolution routines, including:

  • Proper treatment of NaN values (ignoring them during convolution and replacing NaN pixels with interpolated values)
  • A single function for 1-D, 2-D, and 3-D convolution
  • Improved options for the treatment of edges
  • Both direct and Fast Fourier Transform (FFT) versions
  • Built-in kernels that are commonly used in Astronomy

Docs here.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.