-
Notifications
You must be signed in to change notification settings - Fork 308
Pycuampcor v2 #922
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
Open
lijun99
wants to merge
46
commits into
isce-framework:main
Choose a base branch
from
lijun99:pycuampcor-v2-devel
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Pycuampcor v2 #922
Changes from 25 commits
Commits
Show all changes
46 commits
Select commit
Hold shift + click to select a range
7710060
PyCuAmpcor: offer an option to fix the starting pixel locations
cf86b83
PyCuAmpcor: merge #622 by rtburns-jpl
3a4fa40
pycuampcor: deallocate memory objects
be9d498
Merge branch 'main' into pycuampcor
1be8be4
pycuampcor: add debug messages for loading the images
9ecd6b9
PyCuAmpcor V2: start with oversampled images
e85f962
PyCuAmpcor: fix the formula for determining the final offset
5f48f3e
PyCuAmpcor: oversampling procedure adjustment
6704ee9
PyCuAmpcor: add extra pads to correlation surface
85c8ec1
PyCuAmpcor: use split spectrum for even sequence oversampling
fe15e7a
PyCuAmpcor: add margin to the loaded secondary chip as well
3d7de1b
PyCuAmpcor: add a python script to plot offset fields
9ad2269
PyCuAmpcor: use a larger area to oversample the reference image
68cf742
PyCuAmpcor: first attemp with double precision - use CUAMPCOR_DOUBLE …
90fe814
PyCuAmpcor-DB: first running version
bcd2b91
PyCuAmpcor-DB: fixed some errors to produce the correct results
0cbd93b
PyCuAmpcor-DP: disable time domain algorithm for (os) window larger t…
67250aa
PyCuAmpcor-DP: change default to single precision
fd28b41
PyCuAmpcor-v2: solution to time domain code for gpus with 48K shared …
c656d72
PyCuAmpcor-V2: in zero padding for FFT oversampling, resort to conven…
1da8c64
PyCuAmpcor-v2: add correlation surface statistics (snr and variance) …
baf1df3
PyCuAmpcor-v2: add the correlation surface peak values to output
cc25c3b
PyCuAmpcor-v2: rename cuAmpcorChunk to cuAmpcorProcessor and use the …
03e3300
PyCuAmpcor-v2: bring back ROIPAC/ampcor workflow (set as default), br…
a6764b8
PyCuAmpcor-v2: repair Readme
7d3eb2c
PyAcuAmpcor-v2: add debug info to cuderamp=1
a3eb6a4
PyAcuAmpcor-v2: fix the search range in presence of extra pads
dd21e68
PyAcuAmpcor-v2: rename two workflows to TwoPass and OnePass wrt the n…
5d070d5
PyCuAmpcor-v2: clarify notations and notes, per PR comments
538704f
PyCuAmpcor-v2: add description for the offset visualization tool plot…
fa3231e
PyCuAmpcor-v2: revert to custom mmap image loader
936d7bc
PyCuAmpcor-v2: 1) fix data types for DP; 2) reduce the search range o…
fbcc209
pycuampcor-v2: fix an error in determining the corrwindow size
80a7c45
pycuampcor-v2: fix also the corrwindow size error for two-pass workflow
cecdee8
pycuampcor-v2: add get_sm_count method - the batch size is recommende…
68a4199
patch getLineBand in some fortran code
1670d80
Merge branch 'main' into pycuampcor-v2-devel
1ea8c27
Merge branch 'fortran-patch' into pycuampcor-v2-devel
9df1506
PyCuAmpcor: patch the scons script for the two different vironments i…
54070c2
pycuampcor-v2: change the order of parameters in classes to suppress …
7acaf20
pycuAmpcor add new workflow to TopsProc, topsApp
yuankailiu 3269450
pycuampcor for topsApp: change the slc access method; add the output …
b99a56c
add OFFSET_PEAKVALUE_FILE to TopsProc
yuankailiu b9572cd
pycuampcor in topsApp: fix the runDenseOffsets script
d2b4104
revert typo changes
yuankailiu c417f5f
pycuampcor-v2: fix the distance in variance estimate in one-pass work…
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| # Early exit if prereqs not available | ||
| if(NOT TARGET GDAL::GDAL | ||
| OR NOT TARGET CUDA::cufft | ||
| OR NOT pybind11_FOUND | ||
| ) | ||
| return() | ||
| endif() | ||
|
|
||
| set(CMAKE_CUDA_STANDARD 11) | ||
| set(CMAKE_CUDA_STANDARD_REQUIRED TRUE) | ||
| set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} --prec-div=true --prec-sqrt=true") | ||
|
|
||
|
|
||
| pybind11_add_module(PyCuAmpcor | ||
| src/PyCuAmpcor.cpp | ||
| src/GDALImage.cpp | ||
| src/SConscript | ||
| src/cuAmpcorProcessor.cpp | ||
| src/cuAmpcorProcessorROIPAC.cpp | ||
| src/cuAmpcorProcessorGrIMP.cpp | ||
| src/cuAmpcorController.cpp | ||
| src/cuAmpcorParameter.cpp | ||
| src/cuArrays.cpp | ||
| src/cuArraysCopy.cu | ||
| src/cuArraysPadding.cu | ||
| src/cuCorrFrequency.cu | ||
| src/cuCorrNormalization.cu | ||
| src/cuCorrNormalizationSAT.cu | ||
| src/cuCorrNormalizer.cpp | ||
| src/cuCorrTimeDomain.cu | ||
| src/cuDeramp.cu | ||
| src/cuEstimateStats.cu | ||
| src/cuOffset.cu | ||
| src/cuOverSampler.cpp | ||
| src/cuSincOverSampler.cu | ||
| src/cudaError.cpp | ||
| src/cudaUtil.cpp | ||
| ) | ||
| target_include_directories(PyCuAmpcor PRIVATE | ||
| src | ||
| ) | ||
| target_link_libraries(PyCuAmpcor PRIVATE | ||
| CUDA::cufft | ||
| GDAL::GDAL | ||
| ) | ||
|
|
||
| InstallSameDir( | ||
| __init__.py | ||
| PyCuAmpcor | ||
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,96 @@ | ||
| # -*- cmake -*- | ||
| # Example with conda: | ||
| # cmake .. -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX -DCMAKE_CUDA_ARCHITECTURES=native -DCMAKE_PREFIX_PATH=${CONDA_PREFIX} -DCMAKE_BUILD_TYPE=Release | ||
|
|
||
| # minimum cmake version to support CUDA and Python | ||
| cmake_minimum_required(VERSION 3.18) | ||
|
|
||
| # project name | ||
| project(PyCuAmpcor LANGUAGES CUDA CXX) | ||
|
|
||
| # C++ Standard | ||
| set(CMAKE_CXX_STANDARD 11) | ||
|
|
||
| # CUDA requirement | ||
| find_package(CUDAToolkit COMPONENTS cudart cufft REQUIRED) | ||
| set(CMAKE_CUDA_STANDARD 11) | ||
| set(CMAKE_CUDA_STANDARD_REQUIRED TRUE) | ||
|
|
||
| if(NOT DEFINED CMAKE_CUDA_ARCHITECTURES) | ||
| set(CMAKE_CUDA_ARCHITECTURES 52 60 70 75 80 86 90) | ||
| endif() | ||
|
|
||
| # python and pybind11 requirement | ||
| find_package(Python 3.6 COMPONENTS Interpreter Development REQUIRED) | ||
| set(PYBIND11_PYTHON_VERSION ${Python_VERSION}) | ||
| set(PYBIND11_FINDPYTHON ON) # Use new FindPython if available | ||
| find_package(pybind11 CONFIG REQUIRED) | ||
|
|
||
| # gdal requirement | ||
| find_package(GDAL REQUIRED) | ||
|
|
||
| # python module | ||
| pybind11_add_module(PyCuAmpcor | ||
| src/PyCuAmpcor.cpp | ||
| src/GDALImage.cpp | ||
| src/cuAmpcorController.cpp | ||
| src/cuAmpcorParameter.cpp | ||
| src/cuArrays.cpp | ||
| src/cuArraysCopy.cu | ||
| src/cuArraysPadding.cu | ||
| src/cuCorrFrequency.cu | ||
| src/cuCorrNormalization.cu | ||
| src/cuCorrNormalizationSAT.cu | ||
| src/cuCorrNormalizer.cpp | ||
| src/cuCorrTimeDomain.cu | ||
| src/cuDeramp.cu | ||
| src/cuEstimateStats.cu | ||
| src/cuOffset.cu | ||
| src/cuOverSampler.cpp | ||
| src/cuSincOverSampler.cu | ||
| src/cudaError.cpp | ||
| src/cudaUtil.cpp | ||
| src/cuAmpcorProcessor.cpp | ||
| src/cuAmpcorProcessorROIPAC.cpp | ||
| src/cuAmpcorProcessorGrIMP.cpp | ||
| ) | ||
|
|
||
| # set_property(TARGET PyCuAmpcor PROPERTY CUDA_SEPARABLE_COMPILATION ON) | ||
|
|
||
| target_include_directories(PyCuAmpcor PRIVATE | ||
| src | ||
| ) | ||
|
|
||
| target_link_libraries(PyCuAmpcor PRIVATE | ||
| CUDA::cufft | ||
| GDAL::GDAL | ||
| ) | ||
|
|
||
| if(NOT DEFINED PYTHON_MODULE_DIR) | ||
| set(PYTHON_MODULE_DIR packages CACHE PATH | ||
| "Python module directory (relative to install prefix)") | ||
| endif() | ||
|
|
||
|
|
||
| # Install with skbuild | ||
| if (SKBUILD) | ||
| # Install package | ||
| install(TARGETS PyCuAmpcor | ||
| LIBRARY DESTINATION PyCuAmpcor) | ||
| else() | ||
| # Install package | ||
| set(PYCUAMOCOR_INSTALL_DIR ${Python_SITEARCH}/PyCuAmpcor) | ||
|
|
||
| # Install compiled library | ||
| install(TARGETS PyCuAmpcor | ||
| LIBRARY DESTINATION ${PYCUAMOCOR_INSTALL_DIR}) | ||
|
|
||
| # Install __init__.py | ||
| install(FILES ${CMAKE_SOURCE_DIR}/__init__.py | ||
| DESTINATION ${PYCUAMOCOR_INSTALL_DIR}) | ||
| message(STATUS "not using skbuild, standard install.") | ||
| endif() | ||
|
|
||
|
|
||
|
|
||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the flag used to switch between the old PyCuAmpcor implementation (i.e., the one following the Fortran code) and the new v2 implementation exposed to the user? If it is, it would be helpful to add it here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added.