Skip to content
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

Create Conda package for conda-forge #38

Open
dmentipl opened this issue Nov 22, 2019 · 6 comments
Open

Create Conda package for conda-forge #38

dmentipl opened this issue Nov 22, 2019 · 6 comments
Assignees

Comments

@dmentipl
Copy link

Hi @tommyod. First, thanks very much for KDEpy!

I use KDEpy as part of my smoothed particle hydrodynamics analysis and visualisation software Plonk (https://github.com/dmentipl/plonk). I use it for interpolation of particle quantities to a pixel grid, like in SPLASH (http://users.monash.edu.au/~dprice/splash/).

I have a Conda (https://docs.conda.io/en/latest/) package for Plonk on my channel on Anaconda Cloud (https://anaconda.org/dmentipl). I've also created a Conda package for KDEpy on my channel. However, I would like to put Plonk on conda-forge (https://conda-forge.org/). Typically, for a conda-forge package all dependencies are on conda-forge. Since I depend on KDEpy, I was wondering if you could put KDEpy on conda-forge. I think you would have to do this as you are the author and maintainer of KDEpy.

I have written a meta.yaml file for KDEpy; see below. This file is the file conda-build uses to build KDEpy into a Conda package. You can use this to build the Conda package with conda-build, and upload it to Anaconda Cloud. However, for conda-forge, the procedure seems to be:

  1. Fork https://github.com/conda-forge/staged-recipes.
  2. Add your "recipe".
  3. Issue pull request.

I've tested the build following instructions here (https://conda-forge.org/docs/maintainer/adding_pkgs.html#staging-test-locally), and it seems to work.

Let me know what you think and if you have any questions.

Regards,
Daniel

meta.yaml

{% set name = "KDEpy" %}
{% set version = "1.0.2" %}

package:
  name: "{{ name|lower }}"
  version: "{{ version }}"

source:
  url: "https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz"
  sha256: "6ddeae3f5e20d195b4c60f3416dd8fec08838e16a6f3c8dc857a1fc28f0e58a9"

build:
  number: 0
  skip: True  # [py<35]
  script: "{{ PYTHON }} setup.py install --single-version-externally-managed --record=record.txt"

requirements:
  build:
    - {{ compiler('c') }}
  host:
    - cython
    - matplotlib >=2.2.0
    - numpy >=1.14.2
    - python
    - scipy >=1.0.1
  run:
    - matplotlib >=2.2.0
    - numpy >=1.14.2
    - python
    - scipy >=1.0.1

test:
  imports:
    - KDEpy

about:
  home: "https://github.com/tommyod/KDEpy"
  license: "GNU General Public v3 (GPLv3)"
  license_family: "GPL3"
  summary: "Kernel Density Estimation in Python."

extra:
  recipe-maintainers:
    - tommyod
@tommyod tommyod self-assigned this Nov 22, 2019
@tommyod
Copy link
Owner

tommyod commented Nov 22, 2019

Thanks a lot for this @dmentipl . I will look into it and get back to you soon! 👍

@dmentipl
Copy link
Author

No worries. Thanks!

@dmentipl
Copy link
Author

dmentipl commented Dec 7, 2019

Hi @tommyod, just to let you know, I no longer use KDEpy in Plonk.

I have realized that I require variable bandwidth KDE, plus I need to use the FFT version for performance. So, I have implemented the algorithms I require in Python, compiled with Numba.

As such I no longer need KDEpy to be a conda-forge package. However, I think KDEpy is excellent software, and it would be worthwhile to put it on conda-forge. I'm happy to help with that if you need. But feel free to close this issue if you prefer.

@tommyod
Copy link
Owner

tommyod commented Dec 7, 2019

Thanks for the update! I still want it up on conda forge, but haven't had the time to look at it. I'll keep it issue open. Where is your KDE code? I'd like to take a look.

@dmentipl
Copy link
Author

dmentipl commented Dec 7, 2019

My code is available here.

It's not a general KDE code. I've re-implemented the interpolation subroutines from SPLASH. Interpolating particle data to a pixel grid is the typical method to visualize smoothed particle hydrodynamics simulations. See the SPLASH paper for the technical details.

@syrte
Copy link
Contributor

syrte commented Sep 7, 2021

My code is available here.

It's not a general KDE code. I've re-implemented the interpolation subroutines from SPLASH. Interpolating particle data to a pixel grid is the typical method to visualize smoothed particle hydrodynamics simulations. See the SPLASH paper for the technical details.

To who is curious about the above link (like me), it was moved to https://github.com/dmentipl/plonk/blob/main/src/plonk/visualize/splash.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants