Skip to content

Commit

Permalink
Fixes for pyOpenSci Submission (#94)
Browse files Browse the repository at this point in the history
* Remove GA

* Fix CONTRIBUTING.md links

* Fix CONTRIBUTING.md links

* Move CONTRIBUTING.md

* Update Documentation title
  • Loading branch information
g4brielvs authored Jul 31, 2024
1 parent 00f225d commit 08b7256
Show file tree
Hide file tree
Showing 6 changed files with 62 additions and 57 deletions.
45 changes: 0 additions & 45 deletions CONTRIBUTING.md

This file was deleted.

20 changes: 14 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,21 @@
- Calculate zonal statistics like mean and sum.
- Plot time series of nighttime lights data.

## Installation
## Documentation

The [**BlackMarblePy**](https://pypi.org/project/blackmarblepy) library allows you to interact with and manipulate data from NASA's Black Marble, which provides global nighttime lights data. Below is a guide on how to use the key functionalities of the library.

### Installation

**BlackMarblePy** is available on [PyPI](https://pypi.org) as [blackmarblepy](https://pypi.org/project/blackmarblepy) and can installed using `pip`:

### From PyPI
#### From PyPI

```shell
pip install blackmarblepy
```

### From Source
#### From Source

1. Clone or download this repository to your local machine. Then, navigate to the root directory of the repository:

Expand Down Expand Up @@ -65,7 +69,7 @@ pip install blackmarblepy

The `-e` flag stands for "editable," meaning changes to the source code will immediately affect the installed package.

### Building Documentation Locally
#### Building Documentation Locally

To build the documentation locally, after (1) and (2) above, please follow these steps:

Expand All @@ -83,7 +87,7 @@ To build the documentation locally, after (1) and (2) above, please follow these

The generated documentation will be available in the `_build/html` directory. Open the `index.html` file in a web browser to view it.

## Usage
### Usage

Before downloading and extracting Black Marble data, define the [NASA LAADS archive](https://ladsweb.modaps.eosdis.nasa.gov/archive/allData/5000/VNP46A3/) `bearer` token, and define a region of interest (i.e., `gdf` as a [`geopandas.GeoDataFrame`](https://geopandas.org/en/stable/docs/reference/api/geopandas.GeoDataFrame.html)).

Expand All @@ -99,7 +103,11 @@ daily = bm_raster(
)
```

For more detailed information and examples, please refer to the [documentation](https://worldbank.github.io/blackmarblepy/notebooks/blackmarblepy.html).
For more detailed information and examples, please refer to the [examples](https://worldbank.github.io/blackmarblepy/notebooks/blackmarblepy.html).

### Full API Reference

For a full reference of all available functions and their parameters, please refer to the [official documentation](api/blackmarble.rst).

## Contributing

Expand Down
1 change: 0 additions & 1 deletion docs/CONTRIBUTING.md

This file was deleted.

45 changes: 45 additions & 0 deletions docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# CONTRIBUTING

Thank you for considering contributing! We appreciate your interest in helping us improve our project. By contributing, you agree to abide by our [Code of Conduct](CODE_OF_CONDUCT.md).

Please take a moment to review this document for important information on how to contribute effectively.

## How Can I Contribute?

There are several ways you can contribute to this project:

- **Bug Reports:** If you encounter a bug or unexpected behavior, please open an issue on our GitHub issue tracker. Be sure to include as much detail as possible to help us identify and fix the problem.

- **Feature Requests**: If you have an idea for a new feature or enhancement, please open an issue on our GitHub issue tracker and label it as a "feature request." Describe the feature and its use case in detail.

- **Pull Requests:** If you'd like to contribute code or documentation changes, we encourage you to submit a pull request (PR). Please follow the guidelines outlined in the [Contributing Code](#contributing-code) section below.

- **Documentation:** If you find any errors or have suggestions for improving our documentation, you can submit changes directly through a pull request.

- **Community Engagement:** Help answer questions and engage with other users and contributors on our GitHub Discussions (if applicable).

## Contributing Code

If you're contributing code, please follow these guidelines:

1. **Fork the Repository**: Click the "Fork" button on the top-right corner of this repository on GitHub. This will create a copy of the project in your GitHub account.

2. **Create a Branch:** Create a new branch for your feature or bug fix. Use a clear and descriptive name for your branch, like `feature/my-new-feature` or `bugfix/issue-123`.

3. **Make Changes:** Make your code changes and ensure they adhere to our coding standards.

4. **Test:** Ensure that your changes do not break existing functionality and add tests for new features or bug fixes.

5. **Commit and Push:** Commit your changes with a clear and concise commit message. Reference any related issues or pull requests in your commit message. Push your branch to your forked repository on GitHub.

6. **Create a Pull Request:** Open a pull request against the main branch of this repository. Provide a clear description of your changes and reference any relevant issues. Your PR will be reviewed by maintainers.

7. **Review and Iterate:** Expect feedback and be prepared to make additional changes if necessary. We may request changes, and once everything looks good, your PR will be merged.

## Code of Conduct

Please note that we have a [Code of Conduct](CODE_OF_CONDUCT.md) in place. We expect all contributors to adhere to it, both in interactions within this project and in interactions with other project members.

## Licensing

By contributing to this project, you agree that your contributions will be licensed under the project's [LICENSE](../LICENSE).
2 changes: 1 addition & 1 deletion docs/_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title:
author: Development Data Group
logo: images/logo.png
only_build_toc_files: true
only_build_toc_files: false

repository:
url: https://github.com/worldbank/blackmarblepy
Expand Down
3 changes: 1 addition & 2 deletions docs/_toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,9 @@ format: jb-book
root: README

parts:
- caption: Documentation
- caption: API Reference
chapters:
- file: api/blackmarble.rst
- file: CONTRIBUTING
- caption: Examples
chapters:
- file: notebooks/blackmarblepy.ipynb
Expand Down
3 changes: 1 addition & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"sphinx.ext.napoleon",
"sphinxcontrib.apidoc",
]
external_toc_exclude_missing = True
external_toc_exclude_missing = False
external_toc_path = "_toc.yml"
extra_extensions = ["sphinxcontrib.apidoc"]
html_baseurl = "https://worldbank.github.io/blackmarblepy"
Expand All @@ -50,7 +50,6 @@
"extra_footer": "",
"home_page_in_toc": False,
"announcement": "",
"analytics": {"google_analytics_id": "G-ZWF69GP65G"},
"use_repository_button": True,
"use_edit_page_button": True,
"use_issues_button": True,
Expand Down

0 comments on commit 08b7256

Please sign in to comment.