diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml deleted file mode 100644 index e702fa93..00000000 --- a/.gitlab-ci.yml +++ /dev/null @@ -1,309 +0,0 @@ -# This script is an edited version of the example found at -# https://git.ligo.org/lscsoft/example-ci-project/blob/python/.gitlab-ci.yml -# Each 0th-indentation level is a job that will be run within GitLab CI -# The only exception are a short list of reserved keywords -# -# https://docs.gitlab.com/ee/ci/yaml/#gitlab-ci-yml - -# stages is a reserved keyword that defines job dependencies and -# parallelization. each stage runs in parallel but must complete -# before the next stage begins - -stages: - - initial - - test - - docs - - deploy - -# ------------------- Initial stage ------------------------------------------- - -.list-env: &list-env - - PREFIX="$(dirname $(which python))/.." - - if [ -d "${PREFIX}/conda-meta" ]; then - conda list --prefix "${PREFIX}" --show-channel-urls; - else - python -m pip list installed; - fi - -# Check author list is up to date -authors: - stage: initial - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python310 - script: - - python test/check_author_list.py - -# Test containers scripts are up to date -containers: - stage: initial - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - script: - - cd containers - - python write_dockerfiles.py #HACK - # Fail if differences exist. If this fails, you may need to run - # write_dockerfiles.py and commit the changes. - - git diff --exit-code - - cp env-template.yml env.yml - - echo " - python=3.11" >> env.yml - - mamba env create -f env.yml -n test --dry-run - -.test-python: &test-python - stage: initial - image: python - script: - - python -m pip install . - - *list-env - - python -c "import bilby" - - python -c "import bilby.bilby_mcmc" - - python -c "import bilby.core" - - python -c "import bilby.core.prior" - - python -c "import bilby.core.sampler" - - python -c "import bilby.core.utils" - - python -c "import bilby.gw" - - python -c "import bilby.gw.detector" - - python -c "import bilby.gw.eos" - - python -c "import bilby.gw.likelihood" - - python -c "import bilby.gw.sampler" - - python -c "import bilby.hyper" - - python -c "import cli_bilby" - - python test/import_test.py - - for script in $(pip show -f bilby | grep "bin\/" | xargs -I {} basename {}); do - ${script} --help; - done - -basic-3.10: - <<: *test-python - image: python:3.10 - -basic-3.11: - <<: *test-python - image: python:3.11 - -basic-3.12: - <<: *test-python - image: python:3.12 - -.test-samplers-import: &test-samplers-import - stage: initial - script: - - python -m pip install . - - *list-env - - pytest test/test_samplers_import.py -v - -import-samplers-3.10: - <<: *test-samplers-import - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python310 - -import-samplers-3.11: - <<: *test-samplers-import - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - -import-samplers-3.12: - <<: *test-samplers-import - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python312 - -.precommits: &precommits - stage: initial - script: - - source activate $PYVERSION - - mkdir -p $CACHE_DIR - - pip install --upgrade pip - - pip --cache-dir=$CACHE_DIR install --upgrade bilby - - pip --cache-dir=$CACHE_DIR install . - # Run precommits (flake8, spellcheck, isort, no merge conflicts, etc) - - pre-commit run --all-files --verbose --show-diff-on-failure - -precommits-py3.11: - <<: *precommits - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - variables: - CACHE_DIR: ".pip311" - PYVERSION: "python311" - -install: - stage: initial - parallel: - matrix: - - EXTRA: [gw, mcmc, all] - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - script: - - pip install .[$EXTRA] - -# ------------------- Test stage ------------------------------------------- - -.unit-tests: &unit-test - stage: test - script: - - python -m pip install . - - *list-env - - - pytest --cov=bilby --durations 10 - -python-3.10: - <<: *unit-test - needs: ["basic-3.10"] - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python310 - -python-3.11: - <<: *unit-test - needs: ["basic-3.11", "precommits-py3.11"] - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - after_script: - - coverage html - - coverage xml - coverage: '/(?i)total.*? (100(?:\.0+)?\%|[1-9]?\d(?:\.\d+)?\%)$/' - artifacts: - reports: - coverage_report: - coverage_format: cobertura - path: coverage.xml - paths: - - htmlcov/ - expire_in: 30 days - -python-3.12: - <<: *unit-test - needs: ["basic-3.12"] - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python312 - -.test-sampler: &test-sampler - stage: test - script: - - python -m pip install .[all] - - *list-env - - pytest test/integration/sampler_run_test.py --durations 10 -v - -python-3.10-samplers: - <<: *test-sampler - needs: ["basic-3.10"] - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python310 - -python-3.11-samplers: - <<: *test-sampler - needs: ["basic-3.11", "precommits-py3.11"] - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - -python-3.12-samplers: - <<: *test-sampler - needs: ["basic-3.12"] - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python312 - -integration-tests-python-3.11: - stage: test - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - needs: ["basic-3.11", "precommits-py3.11"] - only: - - schedules - script: - - python -m pip install . - - *list-env - # Run tests which are only done on schedule - - pytest test/integration/example_test.py - -.plotting: &plotting - stage: test - only: - - schedules - script: - - python -m pip install . - - *list-env - - pytest test/gw/plot_test.py - -plotting-python-3.10: - <<: *plotting - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python310 - needs: ["basic-3.10"] - -plotting-python-3.11: - <<: *plotting - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - needs: ["basic-3.11", "precommits-py3.11"] - -plotting-python-3.12: - <<: *plotting - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python312 - needs: ["basic-3.12"] - -# ------------------- Docs stage ------------------------------------------- - -docs: - stage: docs - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python311 - before_script: - - python -m ipykernel install - script: - # Make the documentation - - python -m pip install . - - python -m pip install myst_parser # only for testing purposes - remove once test image is generating correctly - - cd examples/tutorials - - jupyter nbconvert --to notebook --execute *.ipynb --output-dir ../../docs - - cd ../../docs - - make clean - - make html - - artifacts: - paths: - - docs/_build/html/ - -# ------------------- Deploy stage ------------------------------------------- - -pages: - stage: deploy - needs: ["docs", "python-3.11"] - script: - - mkdir public/ - - mv htmlcov/ public/ - - mv docs/_build/html/* public/ - artifacts: - paths: - - public - expire_in: 30 days - only: - - master - -.build-container: &build-container - stage: deploy - image: docker:20.10.23 - needs: ["containers"] - rules: - - if: $CI_PIPELINE_SOURCE == "merge_request_event" - changes: - compare_to: 'refs/heads/main' - paths: - - containers/* - when: manual - - if: $CI_PIPELINE_SOURCE == "schedule" - script: - - cd containers - - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY - - cp v3-dockerfile-test-suite-$PYVERSION Dockerfile - - docker build --tag v3-bilby-$PYVERSION . - - docker image tag v3-bilby-$PYVERSION containers.ligo.org/lscsoft/bilby/v2-bilby-$PYVERSION:latest - - docker image push containers.ligo.org/lscsoft/bilby/v2-bilby-$PYVERSION:latest - -build-python310-container: - <<: *build-container - variables: - PYVERSION: "python310" - -build-python311-container: - <<: *build-container - variables: - PYVERSION: "python311" - -build-python312-container: - <<: *build-container - variables: - PYVERSION: "python312" - -pypi-release: - stage: deploy - image: containers.ligo.org/lscsoft/bilby/v2-bilby-python310 - variables: - TWINE_USERNAME: $PYPI_USERNAME - TWINE_PASSWORD: $PYPI_PASSWORD - before_script: - - python -m build --sdist --wheel --outdir dist/ . - script: - - twine upload dist/* - only: - - tags diff --git a/CHANGELOG.md b/CHANGELOG.md index 564b6a37..5f7fc029 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # All notable changes will be documented in this file +**Note:** following the migration from LIGO GitLab to GitHub, the links in this changelog have been retroactively updated, see [this PR](https://github.com/bilby-dev/bilby/pull/36). +The original MRs are only visible on the [LIGO GitLab repository](https://git.ligo.org/lscsoft/bilby/-/merge_requests?scope=all&state=all) + ## [Unreleased] @@ -518,9 +521,7 @@ Version 1.0.1 release of bilby Version 1.0 release of bilby ### Changes -- Minor bug fixes and typo changes only from 0.6.9, see -git.ligo.org/lscsoft/bilby/-/merge_requests?scope=all&utf8=%E2%9C%93&state=merged&milestone_title=1.0.0 -for details +- Minor bug fixes and typo changes only from 0.6.9, see the [1.0.0 milestone](https://github.com/bilby-dev/bilby/-/merge_requests?scope=all&state=all&milestone_title=1.0.0) for details ## [0.6.9] 2020-05-21 ### Changes @@ -1032,7 +1033,7 @@ re-instantiate the Prior in most cases ### Added - InterferometerStrainData now handles both time-domain and frequencu-domain data -- Adds documentation on setting data (https://lscsoft.docs.ligo.org/bilby/transient-gw-data.html) +- Adds documentation on setting data (https://bilby-dev.github.io/bilby/transient-gw-data.html) - Checkpointing for `dynesty`: the sampling will be checkpointed every 10 minutes (approximately) and can be resumed. - Add functionality to plot multiple results in a corner plot, see `bilby.core.result.plot_multiple()`. - Likelihood evaluations are now saved along with the posteriors. @@ -1059,38 +1060,38 @@ First `pip` installable version https://pypi.org/project/BILBY/ . - Major effort to update all docstrings and add some documentation. - Marginalized likelihoods. - Examples of searches for gravitational waves from a Supernova and using a sine-Gaussian. -- A `PriorSet` to handle sets of priors and allows reading in from a standardised prior file (see https://lscsoft.docs.ligo.org/bilby/prior.html). +- A `PriorSet` to handle sets of priors and allows reading in from a standardised prior file (see https://bilby-dev.github.io/bilby/prior.html). - A standardised file for storing detector data. ### Removed - All chainconsumer dependency as this was causing issues. -[Unreleased]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.3.0...master -[2.3.0]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.2.3...v2.3.0 -[2.2.3]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.2.2...v2.2.3 -[2.2.2]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.2.1...v2.2.2 -[2.2.1]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.2.0...v2.2.1 -[2.2.0]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.1.2...v2.2.0 -[2.1.2]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.1.1...v2.1.2 -[2.1.1]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.1.0...v2.1.1 -[2.1.0]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.0.2...v2.1.0 -[2.0.2]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.0.1...v2.0.2 -[2.0.1]: https://git.ligo.org/lscsoft/bilby/-/compare/v2.0.0...v2.0.1 -[2.0.0]: https://git.ligo.org/lscsoft/bilby/-/compare/v1.4.1...v2.0.0 -[1.4.1]: https://git.ligo.org/lscsoft/bilby/-/compare/v1.4.0...v1.4.1 -[1.4.0]: https://git.ligo.org/lscsoft/bilby/-/compare/1.3.0...v1.4.0 -[1.3.0]: https://git.ligo.org/lscsoft/bilby/-/compare/1.2.1...1.3.0 -[1.2.1]: https://git.ligo.org/lscsoft/bilby/-/compare/1.2.0...1.2.1 -[1.2.0]: https://git.ligo.org/lscsoft/bilby/-/compare/1.1.5...1.2.0 -[1.1.5]: https://git.ligo.org/lscsoft/bilby/-/compare/1.1.4...1.1.5 -[1.1.4]: https://git.ligo.org/lscsoft/bilby/-/compare/1.1.2...1.1.4 -[1.1.3]: https://git.ligo.org/lscsoft/bilby/-/compare/1.1.2...1.1.3 -[1.1.2]: https://git.ligo.org/lscsoft/bilby/-/compare/1.1.1...1.1.2 -[1.1.1]: https://git.ligo.org/lscsoft/bilby/-/compare/1.1.0...1.1.1 -[1.1.0]: https://git.ligo.org/lscsoft/bilby/-/compare/1.0.4...1.1.0 -[1.0.4]: https://git.ligo.org/lscsoft/bilby/-/compare/1.0.3...1.0.4 -[1.0.3]: https://git.ligo.org/lscsoft/bilby/-/compare/1.0.2...1.0.3 -[1.0.2]: https://git.ligo.org/lscsoft/bilby/-/compare/1.0.1...1.0.2 -[1.0.1]: https://git.ligo.org/lscsoft/bilby/-/compare/1.0.0...1.0.1 -[1.0.0]: https://git.ligo.org/lscsoft/bilby/-/compare/0.6.9...1.0.0 +[Unreleased]: https://github.com/bilby-dev/bilby/compare/v2.3.0...main +[2.3.0]: https://github.com/bilby-dev/bilby/compare/v2.2.3...v2.3.0 +[2.2.3]: https://github.com/bilby-dev/bilby/compare/v2.2.2...v2.2.3 +[2.2.2]: https://github.com/bilby-dev/bilby/compare/v2.2.1...v2.2.2 +[2.2.1]: https://github.com/bilby-dev/bilby/compare/v2.2.0...v2.2.1 +[2.2.0]: https://github.com/bilby-dev/bilby/compare/v2.1.2...v2.2.0 +[2.1.2]: https://github.com/bilby-dev/bilby/compare/v2.1.1...v2.1.2 +[2.1.1]: https://github.com/bilby-dev/bilby/compare/v2.1.0...v2.1.1 +[2.1.0]: https://github.com/bilby-dev/bilby/compare/v2.0.2...v2.1.0 +[2.0.2]: https://github.com/bilby-dev/bilby/compare/v2.0.1...v2.0.2 +[2.0.1]: https://github.com/bilby-dev/bilby/compare/v2.0.0...v2.0.1 +[2.0.0]: https://github.com/bilby-dev/bilby/compare/v1.4.1...v2.0.0 +[1.4.1]: https://github.com/bilby-dev/bilby/compare/v1.4.0...v1.4.1 +[1.4.0]: https://github.com/bilby-dev/bilby/compare/1.3.0...v1.4.0 +[1.3.0]: https://github.com/bilby-dev/bilby/compare/1.2.1...1.3.0 +[1.2.1]: https://github.com/bilby-dev/bilby/compare/1.2.0...1.2.1 +[1.2.0]: https://github.com/bilby-dev/bilby/compare/1.1.5...1.2.0 +[1.1.5]: https://github.com/bilby-dev/bilby/compare/1.1.4...1.1.5 +[1.1.4]: https://github.com/bilby-dev/bilby/compare/1.1.2...1.1.4 +[1.1.3]: https://github.com/bilby-dev/bilby/compare/1.1.2...1.1.3 +[1.1.2]: https://github.com/bilby-dev/bilby/compare/1.1.1...1.1.2 +[1.1.1]: https://github.com/bilby-dev/bilby/compare/1.1.0...1.1.1 +[1.1.0]: https://github.com/bilby-dev/bilby/compare/1.0.4...1.1.0 +[1.0.4]: https://github.com/bilby-dev/bilby/compare/1.0.3...1.0.4 +[1.0.3]: https://github.com/bilby-dev/bilby/compare/1.0.2...1.0.3 +[1.0.2]: https://github.com/bilby-dev/bilby/compare/1.0.1...1.0.2 +[1.0.1]: https://github.com/bilby-dev/bilby/compare/1.0.0...1.0.1 +[1.0.0]: https://github.com/bilby-dev/bilby/compare/0.6.9...1.0.0 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 9d151d79..9d257bf6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -8,7 +8,7 @@ have some familiarity with python and git. 3. [Automated Code Checking](#automated-code-checking) 4. [Unit Testing](#unit-testing) 5. [Code relevance](#code-relevance) -6. [Merge requests](#merge-requests) +6. [Pull requests](#pull-requets) 7. [Typical workflow](#typical-workflow) 8. [Hints and tips](#hints-and-tips) 9. [Code overview](#code-overview) @@ -17,7 +17,7 @@ have some familiarity with python and git. ## Code of Conduct Everyone participating in the bilby community, and in particular in our issue -tracker, merge requests, and chat channels, is expected to treat other people +tracker, pull requests, and chat channels, is expected to treat other people with respect and follow the guidelines articulated in the [Python Community Code of Conduct](https://www.python.org/psf/codeofconduct/). Furthermore, members of the LVK collaboration must follow the [LVK Code of Conduct](https://dcc.ligo.org/LIGO-M1900037/public). @@ -80,7 +80,7 @@ usual help channels. ## Unit Testing -Unit tests are an important part of code development, helping to minimize the number of undetected bugs which may be present in a merge request. They also greatly expedite the review of code, and can even help during the initial development if used properly. Accordingly, bilby requires unit testing for any changes with machine readable inputs and outputs (i.e. pretty much everything except plotting). +Unit tests are an important part of code development, helping to minimize the number of undetected bugs which may be present in a pull request. They also greatly expedite the review of code, and can even help during the initial development if used properly. Accordingly, bilby requires unit testing for any changes with machine readable inputs and outputs (i.e. pretty much everything except plotting). Unit testing is integrated into the CI/CD pipeline, and uses the builtin unittest package. Tests should be written into the `test/` directory which corresponds to their location within the package, such that, for example, a change to `bilby/gw/conversion.py` should go into `test/gw/conversion_test.py`. To run a single test locally, one may simply do `pytest /path/to/test TestClass.test_name`, whereas to run all the tests in a given test file one may omit the class and function. @@ -133,16 +133,16 @@ code. Adding code into the bilby source comes with advantages, but also adds complexity and review burden to the project. If you are unsure where it should live, open an issue to discuss it. -## Merge requests +## Pull requests All changes to the code base go through the [merge-request workflow](https://docs.gitlab.com/ee/user/project/merge_requests/) Anyone may review your code and you should expect a few comments and questions. Once all -discussions are resolved, core developers will approve the merge request and +discussions are resolved, core developers will approve the pull request and then merge it into the master branch. If you go a few days without a reply, please feel free to ping the thread by adding a new comment. -All merge requests should be focused: they should aim to either add one +All pull requests should be focused: they should aim to either add one feature, solve one bug, or fix some stylistic issues. If multiple changes are lumped together it can slow down the process and make it harder to review. @@ -159,18 +159,18 @@ behaviour. See the [Code style](#code-style) Section for an overview. **Reviewing Changes** -If you are reviewing a merge request (either as a core developer or just as an +If you are reviewing a pull request (either as a core developer or just as an interested party) please keep these three things in mind * If you open a discussion, be timely in responding to the submitter. Note, the reverse does not need to apply. -* Keep your questions/comments focused on the scope of the merge request. If +* Keep your questions/comments focused on the scope of the pull request. If while reviewing the code you notice other things which could be improved, open a new issue. -* Be supportive - merge requests represent a lot of hard work and effort and +* Be supportive - pull requests represent a lot of hard work and effort and should be encouraged. -Reviewers should follow these rules when processing merge requests: +Reviewers should follow these rules when processing pull requests: * Always wait for tests to pass before merging MRs. * Delete branches for merged MRs (by core devs pushing to the main repo). @@ -182,20 +182,20 @@ Reviewers should follow these rules when processing merge requests: Bilby uses the fork and merge model for code review and contributing to the repository. As such, you won't be able to push changes to the master branch. Instead, you'll need to create a fork, make your changes on a feature branch, -then submit a merge request. The following subsections walk you through how to +then submit a pull request. The following subsections walk you through how to do this. ### Step a) getting started All the code lives in a git repository (for a short introduction to git, see -[this tutorial](https://docs.gitlab.com/ee/gitlab-basics/start-using-git.html)) -which is hosted here: https://git.ligo.org/lscsoft/bilby. If you haven't -already, you should -[fork](https://docs.gitlab.com/ee/gitlab-basics/fork-project.html) the +[this tutorial](https://docs.github.com/en/get-started/using-git/about-git)) +which is hosted here: https://github.com/bilby-dev/bilby. +If you haven't already, you should +[fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo) the repository and clone your fork, i.e., on your local machine run ```bash -$ git clone git@git.ligo.org:albert.einstein/bilby.git +$ git clone git@github.com:/bilby.git ``` replacing the SSH url to that of your fork. This will create a directory @@ -224,14 +224,14 @@ automatically be updated. ### Step b) Updating your fork If you already have a fork of bilby, and are starting work on a new project you -can link your clone to the main (`lscsoft`) repository and pull in changes that +can link your clone to the main (`bilby-dev`) repository and pull in changes that have been merged since the time you created your fork, or last updated: **Link your fork to the main repository:** from the directory `/bilby` containing a local copy of the code: ```bash -$ git remote add lscsoft https://git.ligo.org/lscsoft/bilby +$ git remote add upstream https://github.com/bilby-dev/bilby ``` You can see which "remotes" you have available by running @@ -240,10 +240,10 @@ You can see which "remotes" you have available by running $ git remote -v ``` -**Fetch new changes from the `lscsoft` repo:** +**Fetch new changes from the `upstream` repo:** ```bash -$ git pull lscsoft master +$ git pull upstream main ``` ### Step c) Creating a new feature branch @@ -253,8 +253,8 @@ separate from other work, simplifying review and merging once the work is done. To create a new feature branch: ```bash -$ git pull lscsoft -$ git checkout -b my-new-feature lscsoft/master +$ git fetch upstream +$ git checkout -b my-new-feature upstream/main ``` ### Step d) Hack away @@ -278,7 +278,7 @@ Correct a typo at L1 of /bilby/my_awesome_feature.py which returned a dictionary For more discussion of best practices, see e.g. [this blog](https://chris.beams.io/posts/git-commit/). -4. Push your changes to the remote copy of your fork on git.ligo.org +4. Push your changes to the remote copy of your fork on github.com ```bash git push origin my-new-feature @@ -291,20 +291,19 @@ new branch and the `origin` remote: git push --set-upstream origin my-new-feature ``` -### Step e) Open a Merge Request +### Step e) Open a Pull Request When you feel that your work is finished, or if you want feedback on it, you -should create a Merge Request to propose that your changes be merged into the -main (`lscsoft`) repository. +should create a Pull Request to propose that your changes be merged into the +main (`bilby-dev`) repository. After you have pushed your new feature branch to `origin`, you should find a new button on the [bilby repository home -page](https://git.ligo.org/lscsoft/bilby) inviting you to create a Merge +page](https://github.com/bilby-dev/bilby) inviting you to create a Pull Request out of your newly pushed branch. You should click the button, and proceed to fill in the title and description boxes on the MR page. If you are -still working on the merge request and don’t want it to be merged accidentally, -add the string "WIP", "work in progress" or "do not merge" (not -case-sensitive), to the title. +still working on the pull request and don’t want it to be merged accidentally, +you can [convert it to a draft](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/changing-the-stage-of-a-pull-request). Once the request has been opened, one of the maintainers will assign someone to review the change. @@ -314,10 +313,10 @@ review the change. ### Licence When submitting a MR, please don't include any license information in your code. Our repository is -[licensed](https://git.ligo.org/lscsoft/bilby/blob/master/LICENSE.md). When -submitting your merge request, we will assume you have read and agreed to the +[licensed](https://github.com/bilby-dev/bilby/blob/main/LICENSE.md). When +submitting your pull request, we will assume you have read and agreed to the terms of [the -license](https://git.ligo.org/lscsoft/bilby/blob/master/LICENSE.md). +license](https://github.com/bilby-dev/bilby/blob/main/LICENSE.md). ### Removing previously installed versions @@ -347,7 +346,7 @@ interpreter. Below, we give a schematic of how the code is structured. This is intended to help orient users and make it easier to contribute. The layout is intended to -define the logic of the code and new merge requests should aim to fit within +define the logic of the code and new pull requests should aim to fit within this logic (unless there is a good argument to change it). For example, code which adds a new sampler should not effect the gravitational-wave specific parts of the code. Note that this document is not programmatically generated and diff --git a/README.rst b/README.rst index d14c44fe..ccb7286e 100644 --- a/README.rst +++ b/README.rst @@ -9,32 +9,32 @@ Fulfilling all your Bayesian dreams. Online material to help you get started: -- `Installation instructions `__ -- `Documentation `__ +- `Installation instructions `__ +- `Documentation `__ If you need help, find an issue, or just have a question/suggestion you can - Join our `Slack workspace `__ (you may need to email the support desk to request an invite) -- Email our support desk: contact+lscsoft-bilby-1846-issue-@support.ligo.org - Ask questions (or search through other users questions and answers) on `StackOverflow `__ using the bilby tag -- For www.git.ligo.org users, submit issues directly through `the issue tracker `__ -- For www.chat.ligo.org users, join the `#bilby-help `__ or `#bilby-devel `__ channels +- Submit issues directly through `the issue tracker `__ +- For chat.ligo.org users, join the `#bilby-help `__ or `#bilby-devel `__ channels +- For LVK-confidential issues, please open `a confidential issue on bilby_pipe `__ -We encourage you to contribute to the development of bilby. This is done via a merge request. For -help in creating a merge request, see `this page -`__ or contact -us directly. For advice on contributing, see `the contributing guide `__. +We encourage you to contribute to the development of bilby. This is done via pull request. For +help in creating a pull request, see `this page +`__ or contact +us directly. For advice on contributing, see `the contributing guide `__. -------------- Citation guide -------------- -Please refer to the `Acknowledging/citing bilby guide `__. +Please refer to the `Acknowledging/citing bilby guide `__. -.. |pipeline status| image:: https://git.ligo.org/lscsoft/bilby/badges/master/pipeline.svg - :target: https://git.ligo.org/lscsoft/bilby/commits/master -.. |coverage report| image:: https://git.ligo.org/lscsoft/bilby/badges/master/coverage.svg +.. |pipeline status| image:: https://github.com/bilby-dev/bilby/actions/workflows/unit-tests.yml/badge.svg + :target: https://github.com/bilby-dev/bilby/commits/master +.. |coverage report| image:: https://github.com/bilby-dev/bilby/badges/master/coverage.svg :target: https://lscsoft.docs.ligo.org/bilby/htmlcov/ .. |pypi| image:: https://badge.fury.io/py/bilby.svg :target: https://pypi.org/project/bilby/ diff --git a/bilby/__init__.py b/bilby/__init__.py index 97a988c8..fb0abff0 100644 --- a/bilby/__init__.py +++ b/bilby/__init__.py @@ -9,9 +9,9 @@ binary coalescence events in interferometric data, but it can also be used for more general problems. -The code, and many examples are hosted at https://git.ligo.org/lscsoft/bilby. +The code, and many examples are hosted at https://github.com/bilby-dev/bilby. For installation instructions see -https://lscsoft.docs.ligo.org/bilby/installation.html. +https://bilby-dev.github.io/bilby/installation.html. """ diff --git a/bilby/core/sampler/dynesty.py b/bilby/core/sampler/dynesty.py index f1617f1e..539531c6 100644 --- a/bilby/core/sampler/dynesty.py +++ b/bilby/core/sampler/dynesty.py @@ -892,7 +892,7 @@ def plot_current_state(self): except Exception as e: logger.warning( f"Unexpected error {e} in dynesty plotting. " - "Please report at git.ligo.org/lscsoft/bilby/-/issues" + "Please report at github.com/bilby-dev/bilby/issues" ) finally: plt.close("all") @@ -918,7 +918,7 @@ def plot_current_state(self): except Exception as e: logger.warning( f"Unexpected error {e} in dynesty plotting. " - "Please report at git.ligo.org/lscsoft/bilby/-/issues" + "Please report at github.com/bilby-dev/bilby/issues" ) finally: plt.close("all") @@ -940,7 +940,7 @@ def plot_current_state(self): except Exception as e: logger.warning( f"Unexpected error {e} in dynesty plotting. " - "Please report at git.ligo.org/lscsoft/bilby/-/issues" + "Please report at github.com/bilby-dev/bilby/issues" ) finally: plt.close("all") @@ -957,7 +957,7 @@ def plot_current_state(self): except Exception as e: logger.warning( f"Unexpected error {e} in dynesty plotting. " - "Please report at git.ligo.org/lscsoft/bilby/-/issues" + "Please report at github.com/bilby-dev/bilby/issues" ) finally: plt.close("all") diff --git a/docs/basics-of-parameter-estimation.txt b/docs/basics-of-parameter-estimation.txt index 35476d90..14a85145 100644 --- a/docs/basics-of-parameter-estimation.txt +++ b/docs/basics-of-parameter-estimation.txt @@ -81,7 +81,7 @@ The code In the following example, also available under `examples/core_examples/linear_regression.py -`_ +`_ we will step through the process of generating some simulated data, writing a likelihood and prior, and running nested sampling using `bilby`. diff --git a/docs/bilby-output.txt b/docs/bilby-output.txt index b0d8f2a6..5e473c2a 100644 --- a/docs/bilby-output.txt +++ b/docs/bilby-output.txt @@ -99,5 +99,5 @@ Visualising the results ----------------------- Bilby also provides some useful built-in plotting tools. Some examples on how to visualise results using these tools (and how to extend them) are shown in -one of the tutorials at `visualising_the_results.ipynb `_. +one of the tutorials at `visualising_the_results.ipynb `_. diff --git a/docs/compact-binary-coalescence-parameter-estimation.txt b/docs/compact-binary-coalescence-parameter-estimation.txt index 22a04394..71bf67e9 100644 --- a/docs/compact-binary-coalescence-parameter-estimation.txt +++ b/docs/compact-binary-coalescence-parameter-estimation.txt @@ -3,7 +3,7 @@ Compact binary coalescence parameter estimation =============================================== In `this example -`_, +`_, we demonstrate how to generate simulated data for a binary black hole coalescence observed by the two LIGO interferometers at Hanford and Livingston for all parameters in the `IMRPhenomPv2` waveform model. @@ -11,7 +11,7 @@ for all parameters in the `IMRPhenomPv2` waveform model. The code will take around 15 hours to run. For testing, you may prefer to run the `4-parameter CBC tutorial -`__. +`__. .. literalinclude:: /../examples/gw_examples/injection_examples/standard_15d_cbc_tutorial.py :language: python diff --git a/docs/conf.py b/docs/conf.py index e4641bc4..b2b3ffa5 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -41,7 +41,7 @@ def git_upstream_url(): if url[:5] != "https": url = f"https://{url}" except subprocess.CalledProcessError: - url = "https://git.ligo.org/lscsoft/bilby" + url = "https://github.com/bilby-dev/bilby" return url @@ -247,4 +247,4 @@ def linkcode_resolve(domain, info): except Exception: return - return f"{GITURL}/-/tree/{GITHASH}/{file}#L{start}-L{end}" + return f"{GITURL}/tree/{GITHASH}/{file}#L{start}-L{end}" diff --git a/docs/examples.txt b/docs/examples.txt index e11954fb..a3bc2341 100644 --- a/docs/examples.txt +++ b/docs/examples.txt @@ -2,26 +2,26 @@ Examples ======== -1. `General inference examples `_: +1. `General inference examples `_: - * `A simple Gaussian likelihood `_: a good example to see how to write your own likelihood. - * `Linear regression for unknown noise `_: fitting to general time-domain data. + * `A simple Gaussian likelihood `_: a good example to see how to write your own likelihood. + * `Linear regression for unknown noise `_: fitting to general time-domain data. -2. `Examples of injecting and recovering data `__: +2. `Examples of injecting and recovering data `__: - * `4-parameter CBC tutorial `__ - * `15-parameter CBC tutorial `__ - * `Create your own source model `__ - * `Create your own time-domain source model `__ - * `How to specify the prior `__ - * `Using a partially marginalized likelihood `__ - * `Injecting and recovering a neutron-star equation of state `__ + * `4-parameter CBC tutorial `__ + * `15-parameter CBC tutorial `__ + * `Create your own source model `__ + * `Create your own time-domain source model `__ + * `How to specify the prior `__ + * `Using a partially marginalized likelihood `__ + * `Injecting and recovering a neutron-star equation of state `__ -3. `Examples using open data `__: +3. `Examples using open data `__: - * `Analysing the first Binary Black hole detection, GW150914 `__ + * `Analysing the first Binary Black hole detection, GW150914 `__ -4. `Notebook-style tutorials `__: +4. `Notebook-style tutorials `__: - * `Comparing different samplers `__ - * `Visualising the output `__ + * `Comparing different samplers `__ + * `Visualising the output `__ diff --git a/docs/gw_prior.txt b/docs/gw_prior.txt index 8ec12a1f..24f59074 100644 --- a/docs/gw_prior.txt +++ b/docs/gw_prior.txt @@ -96,5 +96,5 @@ Priors using a Jupyter notebook Bilby saves as output the prior volume sampled. You might also find useful to produce priors directly from a Jupyter notebook. You can have a look at one of the Bilby tutorials to check how you define and plot priors in a Jupyter notebook: -`making_priors.ipynb `_. +`making_priors.ipynb `_. diff --git a/docs/installation.txt b/docs/installation.txt index 0583ce87..df28d460 100644 --- a/docs/installation.txt +++ b/docs/installation.txt @@ -57,7 +57,7 @@ Clone the repository, install the requirements, and then install the software: .. code-block:: console - $ git clone git@git.ligo.org:lscsoft/bilby.git + $ git clone git@git@github.com:bilby-dev/bilby.git $ cd bilby/ $ pip install -r requirements.txt $ pip install . @@ -74,20 +74,6 @@ try to run the examples. to fetch the tags so that when you install from source your version information is up to date. -.. note:: - If you do not have a git.ligo account, and receive an error message: - - .. code-block:: console - - git@git.ligo.org: Permission denied (publickey,gssapi-keyex,gssapi-with-mic). - fatal: Could not read from remote repository. - - Then you need to use the HTTPS URL, e.g., replace the first line above with - - .. code-block:: console - - $ git clone https://git.ligo.org/lscsoft/bilby.git - .. note:: You may be use to using :code:`$ python setup.py install` to install software from source. While it is possible to do this, current recommentations from @@ -99,11 +85,11 @@ Installing optional requirements ================================ The `requirements.txt -`_ is a +`_ is a minimal set of requirements for using :code:`bilby`. Additionally, we provide: 1. The file `optional_requirements.txt -`_ +`_ which you should install if you plan to use :code:`bilby` for gravitational-wave data analysis. diff --git a/docs/likelihood.txt b/docs/likelihood.txt index 79f917ff..0ab6733f 100644 --- a/docs/likelihood.txt +++ b/docs/likelihood.txt @@ -65,7 +65,7 @@ This demonstrates the two required features of a :code:`bilby` #. It has a :code:`log_likelihood` method which, when called returns the log likelihood for all the data. -You can find an example that uses this likelihood `here `_. +You can find an example that uses this likelihood `here `_. .. tip:: @@ -155,7 +155,7 @@ be the dependent variable. as the case when there is no signal (i.e., :math:`y(x; \theta)=0`). You can see an example of this likelihood in the `linear regression example -`_. +`_. General likelihood for fitting a function :math:`y(x)` to some data with unknown noise -------------------------------------------------------------------------------------- @@ -213,7 +213,7 @@ instantiating the likelihood:: We provide this general-purpose class as part of bilby :code:`bilby.core.likelihood.GaussianLikleihood` -An example using this likelihood can be found `on this page `_. +An example using this likelihood can be found `on this page `_. Common likelihood functions --------------------------- diff --git a/docs/plugins.txt b/docs/plugins.txt index a73f0ce4..b17ba739 100644 --- a/docs/plugins.txt +++ b/docs/plugins.txt @@ -56,7 +56,7 @@ Sampler plugin library This is a list of known sampler plugins. if you don't see your plugin listed here, we encourage you to open a -`merge request `_ to add it. +`pull request `_ to add it. - This could be your sampler @@ -89,5 +89,5 @@ Adding a new plugin group ------------------------- If you want to add support for a new plugin group, please -`open an issue `_ +`open an issue `_ to discuss the details with other developers. diff --git a/docs/samplers.txt b/docs/samplers.txt index 7b4a190f..93f921c6 100644 --- a/docs/samplers.txt +++ b/docs/samplers.txt @@ -107,9 +107,9 @@ installed using $ pip install -r sampler_requirements.txt where the file `sampler_requirements.txt -`_ can +`_ can be found in the at the top-level of `the repository -`_ (Note: if you installed from pip, you +`_ (Note: if you installed from pip, you can simply download that file and use the command above). diff --git a/docs/writing-documentation.txt b/docs/writing-documentation.txt index 34c1402f..43573f01 100644 --- a/docs/writing-documentation.txt +++ b/docs/writing-documentation.txt @@ -59,7 +59,7 @@ all of the new/changed files:: $ git commit -m "Adding my documentation for the feature" $ git push origin adding-my-new-documentation -Then, on the web interface create a merge request. +Then, on the web interface create a pull request. Using reStructured text ----------------------- diff --git a/examples/README.rst b/examples/README.rst index 59703acb..7f09c744 100644 --- a/examples/README.rst +++ b/examples/README.rst @@ -10,5 +10,5 @@ notebooks. The :code:`basic_tutorial.py` example discussed in arXiv:1811.02042 has been renamed to `gw_examples/injection_examples/fast_tutorial.py -`_. +`_. diff --git a/setup.py b/setup.py index 5b619120..c9c00e2e 100644 --- a/setup.py +++ b/setup.py @@ -41,7 +41,7 @@ def readfile(filename): description="A user-friendly Bayesian inference library", long_description=long_description, long_description_content_type="text/x-rst", - url="https://git.ligo.org/lscsoft/bilby", + url="https://github.com/bilby-dev/bilby", author="Greg Ashton, Moritz Huebner, Paul Lasky, Colm Talbot", author_email="paul.lasky@monash.edu", license="MIT",