From ac14e6ac2c9a7900f848f3d9af0bbcf8b8c8eda9 Mon Sep 17 00:00:00 2001 From: Dusty Reichwein Date: Mon, 17 Jun 2024 15:35:59 -0700 Subject: [PATCH 1/5] Use extension_helpers to enable OpenMP support in bspline package to avoid windows install problem. --- bin/pypeit_c_enabled | 17 ++++++++- pypeit/bspline/setup_package.py | 66 +++++++-------------------------- 2 files changed, 28 insertions(+), 55 deletions(-) diff --git a/bin/pypeit_c_enabled b/bin/pypeit_c_enabled index 8a21ba246b..b07c54d19b 100755 --- a/bin/pypeit_c_enabled +++ b/bin/pypeit_c_enabled @@ -13,11 +13,24 @@ else: print('Successfully imported bspline C utilities.') try: - from pypeit.bspline.setup_package import extra_compile_args + + # Check for whether OpenMP support is enabled, by seeing if the bspline + # extension was compiled with it. + # + # The extension_helpers code that is run to figure out OMP support runs + # multiple tests to determine compiler version, some of which output to stderr. + # To make the output pretty we redirect those to /dev/null (or equivalent) + import os + import sys + devnull_fd = os.open(os.devnull,os.O_WRONLY) + os.dup2(devnull_fd,sys.stderr.fileno()) + + from pypeit.bspline.setup_package import get_extensions + bspline_extension = get_extensions()[0] except: print("Can't check status of OpenMP support") else: - if '-fopenmp' in extra_compile_args: + if 'openmp' in bspline_extension.extra_compile_args: print('OpenMP compiler support detected.') else: print('OpenMP compiler support not detected. Bspline utilities single-threaded.') diff --git a/pypeit/bspline/setup_package.py b/pypeit/bspline/setup_package.py index 415759c0c1..f085c7e055 100644 --- a/pypeit/bspline/setup_package.py +++ b/pypeit/bspline/setup_package.py @@ -1,50 +1,9 @@ import os import sys -import tempfile, subprocess, shutil from setuptools import Extension +from extension_helpers import add_openmp_flags_if_available -# the most reliable way to check for openmp support in the C compiler is to try to build -# some test code with the -fopenmp flag. openmp provides a big performance boost, but some -# systems, notably apple's version of clang that xcode provides, don't support it out of the box. - -# see http://openmp.org/wp/openmp-compilers/ -omp_test = \ -r""" -#include -#include -int main() { -#pragma omp parallel -printf("Hello from thread %d, nthreads %d\n", omp_get_thread_num(), omp_get_num_threads()); -} -""" - -def check_for_openmp(): - tmpdir = tempfile.mkdtemp() - curdir = os.getcwd() - os.chdir(tmpdir) - - if 'CC' in os.environ: - c_compiler = os.environ['CC'] - else: - c_compiler = 'gcc' - - filename = r'test.c' - with open(filename, 'w') as file: - file.write(omp_test) - with open(os.devnull, 'w') as fnull: - result = subprocess.call([c_compiler, '-fopenmp', filename], - stdout=fnull, stderr=fnull) - - os.chdir(curdir) - # clean up test code - shutil.rmtree(tmpdir) - - # return code from compiler process is 0 if it completed successfully - if result == 0: - return True - else: - return False C_BSPLINE_PKGDIR = os.path.relpath(os.path.dirname(__file__)) @@ -55,16 +14,17 @@ def check_for_openmp(): if not sys.platform.startswith('win'): extra_compile_args.append('-fPIC') -if check_for_openmp(): - extra_compile_args.append('-fopenmp') - extra_link_args = ['-fopenmp'] -else: - extra_link_args = [] def get_extensions(): - return [Extension(name='pypeit.bspline._bspline', sources=SRC_FILES, - extra_compile_args=extra_compile_args, language='c', - extra_link_args=extra_link_args, - export_symbols=['bspline_model', 'solution_arrays', - 'cholesky_band', 'cholesky_solve', - 'intrv'])] + extension = Extension(name='pypeit.bspline._bspline', sources=SRC_FILES, + extra_compile_args=extra_compile_args, language='c', + export_symbols=['bspline_model', 'solution_arrays', + 'cholesky_band', 'cholesky_solve', + 'intrv']) + + # extension_helpers will check for opnmp support by trying to build + # some test code with the appropriate flag. openmp provides a big performance boost, but some + # systems, notably apple's version of clang that xcode provides, don't support it out of the box. + + add_openmp_flags_if_available(extension) + return [extension] \ No newline at end of file From a9f96b017aaf66f11c1301850e4ee19af63ff7ff Mon Sep 17 00:00:00 2001 From: Dusty Reichwein Date: Mon, 17 Jun 2024 16:31:01 -0700 Subject: [PATCH 2/5] Fix bug detecting OpenMP support --- bin/pypeit_c_enabled | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/pypeit_c_enabled b/bin/pypeit_c_enabled index b07c54d19b..746e82cdc1 100755 --- a/bin/pypeit_c_enabled +++ b/bin/pypeit_c_enabled @@ -30,7 +30,8 @@ try: except: print("Can't check status of OpenMP support") else: - if 'openmp' in bspline_extension.extra_compile_args: + # Windows uses -openmp, other environments use -fopenmp + if any(['openmp' in arg for arg in bspline_extension.extra_compile_args]): print('OpenMP compiler support detected.') else: print('OpenMP compiler support not detected. Bspline utilities single-threaded.') From 885cb1823f63bc1a41bd9bf4305109e04891a05a Mon Sep 17 00:00:00 2001 From: Dusty Reichwein Date: Wed, 17 Jul 2024 18:48:11 -0700 Subject: [PATCH 3/5] Update docs for Windows install --- doc/help/run_pypeit.rst | 2 +- doc/include/keck_deimos.sorted.rst | 10 ++--- doc/installing.rst | 24 ++++++++++++ doc/pypeit_par.rst | 62 +++++++++++++++--------------- doc/releases/1.16.1dev.rst | 2 +- 5 files changed, 62 insertions(+), 38 deletions(-) diff --git a/doc/help/run_pypeit.rst b/doc/help/run_pypeit.rst index 60a98ddfc7..43f5329f63 100644 --- a/doc/help/run_pypeit.rst +++ b/doc/help/run_pypeit.rst @@ -4,7 +4,7 @@ usage: run_pypeit [-h] [-v VERBOSITY] [-r REDUX_PATH] [-m] [-s] [-o] [-c] pypeit_file - ## PypeIt : The Python Spectroscopic Data Reduction Pipeline v1.16.1.dev97+g2ab5988a9 + ## PypeIt : The Python Spectroscopic Data Reduction Pipeline v1.16.1.dev97+g2ab5988a9.d20240708 ## ## Available spectrographs include: ## bok_bc, gemini_flamingos1, gemini_flamingos2, gemini_gmos_north_e2v, diff --git a/doc/include/keck_deimos.sorted.rst b/doc/include/keck_deimos.sorted.rst index 828519122f..4e41db2257 100644 --- a/doc/include/keck_deimos.sorted.rst +++ b/doc/include/keck_deimos.sorted.rst @@ -12,17 +12,17 @@ filename | frametype | ra | dec | target | dispname | decker | binning | mjd | airmass | exptime | dispangle | amp | filter1 | lampstat01 | dateobs | utc | frameno | calib DE.20170527.06713.fits | arc,tilt | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.077631 | 1.41291034 | 1.0 | 8099.98291016 | SINGLE:B | OG550 | Kr Xe Ar Ne | 2017-05-27 | 01:51:53.87 | 30 | 0 d0527_0030.fits.gz | arc,tilt | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.077631 | 1.41291034 | 1.0 | 8099.98291016 | SINGLE:B | OG550 | Kr Xe Ar Ne | 2017-05-27 | 01:51:53.87 | 30 | 0 - d0527_0031.fits.gz | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.07851 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:53:10.93 | 31 | 0 DE.20170527.06790.fits | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.07851 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:53:10.93 | 31 | 0 - DE.20170527.06864.fits | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.079356 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:54:24.03 | 32 | 0 + d0527_0031.fits.gz | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.07851 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:53:10.93 | 31 | 0 d0527_0032.fits.gz | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.079356 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:54:24.03 | 32 | 0 - d0527_0033.fits.gz | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.080211 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:55:36.93 | 33 | 0 + DE.20170527.06864.fits | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.079356 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:54:24.03 | 32 | 0 DE.20170527.06936.fits | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.080211 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:55:36.93 | 33 | 0 + d0527_0033.fits.gz | pixelflat,illumflat,trace | 57.99999999999999 | 45.0 | DOME PHLAT | 830G | LongMirr | 1,1 | 57900.080211 | 1.41291034 | 4.0 | 8099.98291016 | SINGLE:B | OG550 | Qz | 2017-05-27 | 01:55:36.93 | 33 | 0 DE.20170527.37601.fits | science | 261.0363749999999 | 19.028166666666667 | P261_OFF | 830G | LongMirr | 1,1 | 57900.435131 | 1.03078874 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 10:26:41.61 | 80 | 0 - d0527_0081.fits.gz | science | 261.0363749999999 | 19.028166666666667 | P261_OFF | 830G | LongMirr | 1,1 | 57900.449842 | 1.01267696 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 10:47:52.92 | 81 | 0 DE.20170527.38872.fits | science | 261.0363749999999 | 19.028166666666667 | P261_OFF | 830G | LongMirr | 1,1 | 57900.449842 | 1.01267696 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 10:47:52.92 | 81 | 0 - DE.20170527.41775.fits | science | 261.0362916666666 | 19.028888888888886 | P261_OFF | 830G | LongMirr | 1,1 | 57900.483427 | 1.00093023 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 11:36:15.35 | 83 | 0 + d0527_0081.fits.gz | science | 261.0363749999999 | 19.028166666666667 | P261_OFF | 830G | LongMirr | 1,1 | 57900.449842 | 1.01267696 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 10:47:52.92 | 81 | 0 d0527_0083.fits.gz | science | 261.0362916666666 | 19.028888888888886 | P261_OFF | 830G | LongMirr | 1,1 | 57900.483427 | 1.00093023 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 11:36:15.35 | 83 | 0 + DE.20170527.41775.fits | science | 261.0362916666666 | 19.028888888888886 | P261_OFF | 830G | LongMirr | 1,1 | 57900.483427 | 1.00093023 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 11:36:15.35 | 83 | 0 DE.20170527.43045.fits | science | 261.0362916666666 | 19.028888888888886 | P261_OFF | 830G | LongMirr | 1,1 | 57900.498135 | 1.00838805 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 11:57:25.35 | 84 | 0 DE.20170527.44316.fits | science | 261.0362916666666 | 19.028888888888886 | P261_OFF | 830G | LongMirr | 1,1 | 57900.512854 | 1.02377681 | 1200.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 12:18:36.71 | 85 | 0 DE.20170527.53184.fits | science | 349.99316666666664 | -5.16575 | Feige 110 | 830G | LongMirr | 1,1 | 57900.615484 | 1.42505162 | 45.0 | 8099.98291016 | SINGLE:B | OG550 | Off | 2017-05-27 | 14:46:24.88 | 93 | 0 diff --git a/doc/installing.rst b/doc/installing.rst index 79e92d9de6..549ee4c744 100644 --- a/doc/installing.rst +++ b/doc/installing.rst @@ -222,6 +222,30 @@ for x86-64: Solutions/Recommendations/Feedback for these installation options are welcome; please `Submit an issue`_. +User Installation on Windows +--------------------------------------------- + +#. Download `Python for Windows `_. + +#. Run the installer. + + * Make sure "Add python.exe to Path" or "Add Python to environment variables" is selected before installing. + * If you have Admin privileges click "Disable path length limit" after the installation succeeds. + +#. Downloand and run the `Visual Studio build tools `_ installer. + + * Only "Desktop Development with C++" needs to be checked. + * Click install + +#. Create a virtual environment as in `Setup a clean python environment `__ and install PypeIt as described above. + +If running ``python`` on Windows brings up a window for the Microsoft Store you may want to change the application alias. +This is under ``Settings -> Apps -> App execution aliases`` on Windows 10 and ``Settings -> Apps -> Advanced app settings -> App execution aliases`` +on Windows 11. Disable the ``App Installer`` options for the ``python.exe`` and ``python3.exe`` executables. + +An alternative for running under Windows is to install the `Windows Subsystem for Linux (WSL) `_. +This in effect allows you to run PypeIt under Linux under Windows. + ---- .. _data_installation: diff --git a/doc/pypeit_par.rst b/doc/pypeit_par.rst index db0e4ae1c8..61283b0fc1 100644 --- a/doc/pypeit_par.rst +++ b/doc/pypeit_par.rst @@ -582,21 +582,21 @@ Collate1DPar Keywords Class Instantiation: :class:`~pypeit.par.pypeitpar.Collate1DPar` -========================= =============== ======= ============================================ ================================================================================================================================================================================================================================================================================================================================================================================================================== -Key Type Options Default Description -========================= =============== ======= ============================================ ================================================================================================================================================================================================================================================================================================================================================================================================================== -``dry_run`` bool .. False If set, the script will display the matching File and Object Ids but will not flux, coadd or archive. -``exclude_serendip`` bool .. False Whether to exclude SERENDIP objects from collating. -``exclude_slit_trace_bm`` list, str .. A list of slit trace bitmask bits that should be excluded. -``flux`` bool .. False If set, the script will flux calibrate using archived sensfuncs before coadding. -``ignore_flux`` bool .. False If set, the script will only coadd non-fluxed spectra even if flux data is present. Otherwise fluxed spectra are coadded if all spec1ds have been fluxed calibrated. -``match_using`` str .. ``ra/dec`` Determines how 1D spectra are matched as being the same object. Must be either 'pixel' or 'ra/dec'. -``outdir`` str .. ``/Users/westfall/Work/packages/pypeit/doc`` The path where all coadded output files and report files will be placed. -``refframe`` str .. .. Perform reference frame correction prior to coadding. Options are: observed, heliocentric, barycentric -``spec1d_outdir`` str .. .. The path where all modified spec1d files are placed. These are only created if flux calibration or refframe correction are asked for. -``tolerance`` str, float, int .. 1.0 The tolerance used when comparing the coordinates of objects. If two objects are within this distance from each other, they are considered the same object. If match_using is 'ra/dec' (the default) this is an angular distance. The defaults units are arcseconds but other units supported by astropy.coordinates.Angle can be used (`e.g.`, '0.003d' or '0h1m30s'). If match_using is 'pixel' this is a float. -``wv_rms_thresh`` float .. .. If set, any objects with a wavelength RMS > this value are skipped, else all wavelength RMS values are accepted. -========================= =============== ======= ============================================ ================================================================================================================================================================================================================================================================================================================================================================================================================== +========================= =============== ======= =============================== ================================================================================================================================================================================================================================================================================================================================================================================================================== +Key Type Options Default Description +========================= =============== ======= =============================== ================================================================================================================================================================================================================================================================================================================================================================================================================== +``dry_run`` bool .. False If set, the script will display the matching File and Object Ids but will not flux, coadd or archive. +``exclude_serendip`` bool .. False Whether to exclude SERENDIP objects from collating. +``exclude_slit_trace_bm`` list, str .. A list of slit trace bitmask bits that should be excluded. +``flux`` bool .. False If set, the script will flux calibrate using archived sensfuncs before coadding. +``ignore_flux`` bool .. False If set, the script will only coadd non-fluxed spectra even if flux data is present. Otherwise fluxed spectra are coadded if all spec1ds have been fluxed calibrated. +``match_using`` str .. ``ra/dec`` Determines how 1D spectra are matched as being the same object. Must be either 'pixel' or 'ra/dec'. +``outdir`` str .. ``/home/dusty/work/PypeIt/doc`` The path where all coadded output files and report files will be placed. +``refframe`` str .. .. Perform reference frame correction prior to coadding. Options are: observed, heliocentric, barycentric +``spec1d_outdir`` str .. .. The path where all modified spec1d files are placed. These are only created if flux calibration or refframe correction are asked for. +``tolerance`` str, float, int .. 1.0 The tolerance used when comparing the coordinates of objects. If two objects are within this distance from each other, they are considered the same object. If match_using is 'ra/dec' (the default) this is an angular distance. The defaults units are arcseconds but other units supported by astropy.coordinates.Angle can be used (`e.g.`, '0.003d' or '0h1m30s'). If match_using is 'pixel' this is a float. +``wv_rms_thresh`` float .. .. If set, any objects with a wavelength RMS > this value are skipped, else all wavelength RMS values are accepted. +========================= =============== ======= =============================== ================================================================================================================================================================================================================================================================================================================================================================================================================== ---- @@ -649,22 +649,22 @@ ReduxPar Keywords Class Instantiation: :class:`~pypeit.par.pypeitpar.ReduxPar` -====================== ============== ======= ============================================ ========================================================================================================================================================================================================================================================================================================================================================================================================== -Key Type Options Default Description -====================== ============== ======= ============================================ ========================================================================================================================================================================================================================================================================================================================================================================================================== -``calwin`` int, float .. 0 The window of time in hours to search for calibration frames for a science frame -``chk_version`` bool .. True If True enforce strict PypeIt version checking to ensure that all files were created with the current version of PypeIt. If set to False, the code will attempt to read out-of-date files and keep going. Beware (!!) that this can lead to unforeseen bugs that either cause the code to crash or lead to erroneous results. I.e., you really need to know what you are doing if you set this to False! -``detnum`` int, list .. .. Restrict reduction to a list of detector indices. In case of mosaic reduction (currently only available for Gemini/GMOS and Keck/DEIMOS) ``detnum`` should be a list of tuples of the detector indices that are mosaiced together. E.g., for Gemini/GMOS ``detnum`` would be ``[(1,2,3)]`` and for Keck/DEIMOS it would be ``[(1, 5), (2, 6), (3, 7), (4, 8)]`` -``ignore_bad_headers`` bool .. False Ignore bad headers (NOT recommended unless you know it is safe). -``maskIDs`` str, int, list .. .. Restrict reduction to a set of slitmask IDs Example syntax -- ``maskIDs = 818006,818015`` This must be used with detnum (for now). -``qadir`` str .. ``QA`` Directory relative to calling directory to write quality assessment files. -``quicklook`` bool .. False Run a quick look reduction? This is usually good if you want to quickly reduce the data (usually at the telescope in real time) to get an initial estimate of the data quality. -``redux_path`` str .. ``/Users/westfall/Work/packages/pypeit/doc`` Path to folder for performing reductions. Default is the current working directory. -``scidir`` str .. ``Science`` Directory relative to calling directory to write science files. -``slitspatnum`` str, list .. .. Restrict reduction to a set of slit DET:SPAT values (closest slit is used). Example syntax -- slitspatnum = DET01:175,DET01:205 or MSC02:2234 If you are re-running the code, (i.e. modifying one slit) you *must* have the precise SPAT_ID index. -``sortroot`` str .. .. A filename given to output the details of the sorted files. If None, the default is the root name of the pypeit file. If off, no output is produced. -``spectrograph`` str .. .. Spectrograph that provided the data to be reduced. See :ref:`instruments` for valid options. -====================== ============== ======= ============================================ ========================================================================================================================================================================================================================================================================================================================================================================================================== +====================== ============== ======= =============================== ========================================================================================================================================================================================================================================================================================================================================================================================================== +Key Type Options Default Description +====================== ============== ======= =============================== ========================================================================================================================================================================================================================================================================================================================================================================================================== +``calwin`` int, float .. 0 The window of time in hours to search for calibration frames for a science frame +``chk_version`` bool .. True If True enforce strict PypeIt version checking to ensure that all files were created with the current version of PypeIt. If set to False, the code will attempt to read out-of-date files and keep going. Beware (!!) that this can lead to unforeseen bugs that either cause the code to crash or lead to erroneous results. I.e., you really need to know what you are doing if you set this to False! +``detnum`` int, list .. .. Restrict reduction to a list of detector indices. In case of mosaic reduction (currently only available for Gemini/GMOS and Keck/DEIMOS) ``detnum`` should be a list of tuples of the detector indices that are mosaiced together. E.g., for Gemini/GMOS ``detnum`` would be ``[(1,2,3)]`` and for Keck/DEIMOS it would be ``[(1, 5), (2, 6), (3, 7), (4, 8)]`` +``ignore_bad_headers`` bool .. False Ignore bad headers (NOT recommended unless you know it is safe). +``maskIDs`` str, int, list .. .. Restrict reduction to a set of slitmask IDs Example syntax -- ``maskIDs = 818006,818015`` This must be used with detnum (for now). +``qadir`` str .. ``QA`` Directory relative to calling directory to write quality assessment files. +``quicklook`` bool .. False Run a quick look reduction? This is usually good if you want to quickly reduce the data (usually at the telescope in real time) to get an initial estimate of the data quality. +``redux_path`` str .. ``/home/dusty/work/PypeIt/doc`` Path to folder for performing reductions. Default is the current working directory. +``scidir`` str .. ``Science`` Directory relative to calling directory to write science files. +``slitspatnum`` str, list .. .. Restrict reduction to a set of slit DET:SPAT values (closest slit is used). Example syntax -- slitspatnum = DET01:175,DET01:205 or MSC02:2234 If you are re-running the code, (i.e. modifying one slit) you *must* have the precise SPAT_ID index. +``sortroot`` str .. .. A filename given to output the details of the sorted files. If None, the default is the root name of the pypeit file. If off, no output is produced. +``spectrograph`` str .. .. Spectrograph that provided the data to be reduced. See :ref:`instruments` for valid options. +====================== ============== ======= =============================== ========================================================================================================================================================================================================================================================================================================================================================================================================== ---- diff --git a/doc/releases/1.16.1dev.rst b/doc/releases/1.16.1dev.rst index fe68fc7496..e51ab2aec0 100644 --- a/doc/releases/1.16.1dev.rst +++ b/doc/releases/1.16.1dev.rst @@ -42,5 +42,5 @@ Under-the-hood Improvements Bug Fixes --------- -- None +- Fix "The system cannot find the file specified" errors when installing on Windows. From 59f2a2151e516484a87107155ab139c7dbe66d75 Mon Sep 17 00:00:00 2001 From: Dusty Reichwein Date: Fri, 19 Jul 2024 14:43:59 -0700 Subject: [PATCH 4/5] Updating docs on how to enable OpenMP for Macs, based on discussion in the developers slack. --- doc/help/run_pypeit.rst | 2 +- doc/installing.rst | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/doc/help/run_pypeit.rst b/doc/help/run_pypeit.rst index 43f5329f63..2870d8a61a 100644 --- a/doc/help/run_pypeit.rst +++ b/doc/help/run_pypeit.rst @@ -4,7 +4,7 @@ usage: run_pypeit [-h] [-v VERBOSITY] [-r REDUX_PATH] [-m] [-s] [-o] [-c] pypeit_file - ## PypeIt : The Python Spectroscopic Data Reduction Pipeline v1.16.1.dev97+g2ab5988a9.d20240708 + ## PypeIt : The Python Spectroscopic Data Reduction Pipeline v1.16.1.dev109+g885cb1823 ## ## Available spectrographs include: ## bok_bc, gemini_flamingos1, gemini_flamingos2, gemini_gmos_north_e2v, diff --git a/doc/installing.rst b/doc/installing.rst index 549ee4c744..f782f4c49b 100644 --- a/doc/installing.rst +++ b/doc/installing.rst @@ -546,7 +546,8 @@ GCC 12.x via ``homebrew``, you would get ``pypeit`` to use it by doing, for exam .. code-block:: console - CC=gcc-12 pip install pypeit + $ export CC=gcc-12 + $ pip install pypeit Basically, ``pypeit`` checks the ``CC`` environment variable for what compiler to use so configure that as needed to use your desired compiler. The ``pypeit_c_enabled`` script can be used to check if From 5788e8a1e65e210a50460df7a06f66f824e7d0ef Mon Sep 17 00:00:00 2001 From: Dusty Reichwein Date: Fri, 19 Jul 2024 18:13:02 -0700 Subject: [PATCH 5/5] Rework from PR comments --- doc/installing.rst | 4 ++-- pypeit/bspline/setup_package.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/installing.rst b/doc/installing.rst index f782f4c49b..1772a7b8f7 100644 --- a/doc/installing.rst +++ b/doc/installing.rst @@ -542,11 +542,11 @@ will work single-threaded if OpenMP is not available. GCC supports OpenMP out of the box, however the ``clang`` compiler that Apple's XCode provides does not. So for optimal performance on Apple hardware, you will want to install GCC via ``homebrew`` or ``macports`` and specify its use when installing ``pypeit``. For example, if you installed -GCC 12.x via ``homebrew``, you would get ``pypeit`` to use it by doing, for example: +GCC via ``homebrew``, you would get ``pypeit`` to use it by doing, for example: .. code-block:: console - $ export CC=gcc-12 + $ export CC=/opt/homebrew/bin/gcc $ pip install pypeit Basically, ``pypeit`` checks the ``CC`` environment variable for what compiler to use so configure diff --git a/pypeit/bspline/setup_package.py b/pypeit/bspline/setup_package.py index f085c7e055..122cff8dc0 100644 --- a/pypeit/bspline/setup_package.py +++ b/pypeit/bspline/setup_package.py @@ -27,4 +27,4 @@ def get_extensions(): # systems, notably apple's version of clang that xcode provides, don't support it out of the box. add_openmp_flags_if_available(extension) - return [extension] \ No newline at end of file + return [extension]