unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: "MadalinIonel.Patrascu@mdc-berlin.de" <MadalinIonel.Patrascu@mdc-berlin.de>
To: Ricardo Wurmus <rekado@elephly.net>
Cc: "46946@debbugs.gnu.org" <46946@debbugs.gnu.org>
Subject: [bug#46946] [ext] Re: [PATCH 1/2] gnu: Add python-bioframe.
Date: Fri, 14 Oct 2022 22:49:10 +0000	[thread overview]
Message-ID: <514a74f8678443cc8f7d57324a9af4b8@mdc-berlin.de> (raw)
In-Reply-To: <87wntm10ca.fsf@elephly.net>

[-- Attachment #1: Type: text/plain, Size: 6487 bytes --]

Dear Ricardo,


I am very sorry that I started this and abandon it!
After a long period, I remembered about this and I found some time to finish this and amend my initial patches as you already pointed out.
The next two definitions are updated and they come with the latest releases and also I solved the issues mentioned.

All the best!

Mădălin Ionel Patrașcu

System Administrator
The Berlin Institute for Medical Systems Biology (BIMSB)
Max Delbrück Center (MDC)
Hannoversche Straße 28
House 101, room 1.89
10115 Berlin, Germany


________________________________
From: Ricardo Wurmus <rekado@elephly.net>
Sent: Thursday, April 1, 2021 17:38
To: Patrascu, Madalin Ionel
Cc: 46946@debbugs.gnu.org
Subject: [ext] Re: [PATCH 1/2] gnu: Add python-bioframe.


Hi Mădălin,

> * gnu/packages/bioinformatics.scm (python-bioframe): New variable.

Thanks for the patch.

Despite all the test inputs the test suite is not actually run:

--8<---------------cut here---------------start------------->8---
starting phase `check'
running "python setup.py" with command "test" and parameters ()
running test
running egg_info
writing bioframe.egg-info/PKG-INFO
writing dependency_links to bioframe.egg-info/dependency_links.txt
writing requirements to bioframe.egg-info/requires.txt
writing top-level names to bioframe.egg-info/top_level.txt
reading manifest file 'bioframe.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no previously-included files matching '__pycache__/*' found anywhere in distribution
warning: no previously-included files matching '*.so' found anywhere in distribution
warning: no previously-included files matching '*.pyd' found anywhere in distribution
warning: no previously-included files matching '*.pyc' found anywhere in distribution
warning: no previously-included files matching '.git*' found anywhere in distribution
warning: no previously-included files matching '.deps/*' found anywhere in distribution
warning: no previously-included files matching '.DS_Store' found anywhere in distribution
writing manifest file 'bioframe.egg-info/SOURCES.txt'
running build_ext
/tmp/guix-build-python-bioframe-0.2.0.drv-0/source/bioframe/io/dask.py:47: NumbaWarning:
Compilation is falling back to object mode WITH looplifting enabled because Function "reg2bins" failed type inference due to: No conversion from list(int64)<iv=None> to int32 for '$262return_value.1', defined at None

File "bioframe/io/dask.py", line 79:
def reg2bins(rbeg, rend):
    <source elided>

    return lst
    ^

During: typing of assignment at /tmp/guix-build-python-bioframe-0.2.0.drv-0/source/bioframe/io/dask.py (79)

File "bioframe/io/dask.py", line 79:
def reg2bins(rbeg, rend):
    <source elided>

    return lst
    ^

  @numba.jit("int32(int32, int32)")
/tmp/guix-build-python-bioframe-0.2.0.drv-0/source/bioframe/io/dask.py:47: NumbaWarning:
Compilation is falling back to object mode WITHOUT looplifting enabled because Function "reg2bins" failed type inference due to: cannot determine Numba type of <class 'numba.core.dispatcher.LiftedLoop'>

File "bioframe/io/dask.py", line 59:
def reg2bins(rbeg, rend):
    <source elided>

    k = 9 + (rbeg >> 23)
    ^

  @numba.jit("int32(int32, int32)")
/gnu/store/sm6k3ar46q11w77s7cc2q1hv33q8p3v0-python-numba-0.51.2/lib/python3.8/site-packages/numba/core/object_mode_passes.py:177: NumbaWarning: Function "reg2bins" was compiled in object mode without forceobj=True, but has lifted loops.

File "bioframe/io/dask.py", line 50:
def reg2bins(rbeg, rend):
    <source elided>

    MAX_BIN = ((1 << 18) - 1) // 7
    ^

  warnings.warn(errors.NumbaWarning(warn_msg,
/gnu/store/sm6k3ar46q11w77s7cc2q1hv33q8p3v0-python-numba-0.51.2/lib/python3.8/site-packages/numba/core/object_mode_passes.py:187: NumbaDeprecationWarning:
Fall-back from the nopython compilation path to the object mode compilation path has been detected, this is deprecated behaviour.

For more information visit https://numba.pydata.org/numba-doc/latest/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit

File "bioframe/io/dask.py", line 50:
def reg2bins(rbeg, rend):
    <source elided>

    MAX_BIN = ((1 << 18) - 1) // 7
    ^

  warnings.warn(errors.NumbaDeprecationWarning(msg,

----------------------------------------------------------------------
Ran 0 tests in 0.000s

OK
phase `check' succeeded after 3.1 seconds
--8<---------------cut here---------------end--------------->8---


I made a couple of cosmestic changes:

--8<---------------cut here---------------start------------->8---
(define-public python-bioframe
  (package
    (name "python-bioframe")
    (version "0.2.0")
    ;; Sources on pypi do not contain requirements.txt
    (source
     (origin
       (method git-fetch)
       (uri (git-reference
             (url "https://github.com/open2c/bioframe")
             (commit (string-append "v" version))))
       (file-name (git-file-name name version))
       (sha256
        (base32
         "0w5xrb93cf3hx3d1lw48a0l1ranghpj260b05b1rpk58wwwcsqfh"))))
    (build-system python-build-system)
    (propagated-inputs
     `(("python-click" ,python-click)
       ("python-numpy" ,python-numpy)
       ("python-pandas" ,python-pandas)
       ("python-requests" ,python-requests)))
    (native-inputs
     `(("python-dask" ,python-dask)             ; for tests
       ("python-matplotlib" ,python-matplotlib) ; for tests
       ("python-numba" ,python-numba)           ; for tests
       ("python-pypairix" ,python-pypairix)     ; for tests
       ("python-pytest" ,python-pytest)
       ("python-wheel" ,python-wheel)))
    (home-page "https://github.com/open2c/bioframe")
    (synopsis "Framework for genomic data analysis using Pandas dataframes")
    (description
     "This package is a library to enable flexible and scalable operations on
genomic interval dataframes in Python.  @code{python-bioframe} enables access;
to a rich set of dataframe operations.  Working in Python enables rapid
visualization (e.g. matplotlib, seaborn) and iteration of genomic analyses.")
    (license license:expat)))
--8<---------------cut here---------------end--------------->8---


Please note that the lack of requirements.txt on pypi shouldn’t be an
obstacle to use the sources from pypi.  It should build just as well.

--
Ricardo

[-- Attachment #2: Type: text/html, Size: 10804 bytes --]

  reply	other threads:[~2022-10-14 22:50 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-05 13:50 [bug#46946] (no subject) Mădălin Ionel Patrașcu
2021-03-05 14:19 ` [bug#46946] [PATCH 1/2] gnu: Add python-bioframe Mădălin Ionel Patrașcu
2021-03-05 14:19   ` [bug#46946] [PATCH 2/2] gnu: Add python-cooltools Mădălin Ionel Patrașcu
2021-04-01 15:38   ` [bug#46946] [PATCH 1/2] gnu: Add python-bioframe Ricardo Wurmus
2022-10-14 22:49     ` MadalinIonel.Patrascu [this message]
2022-10-14 22:52 ` Mădălin Ionel Patrașcu
2022-10-14 22:52   ` [bug#46946] [PATCH 2/2] gnu: Add python-cooltools Mădălin Ionel Patrașcu
2022-11-04 12:53 ` bug#46946: Add python-bioframe, python-cooltools Ricardo Wurmus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=514a74f8678443cc8f7d57324a9af4b8@mdc-berlin.de \
    --to=madalinionel.patrascu@mdc-berlin.de \
    --cc=46946@debbugs.gnu.org \
    --cc=rekado@elephly.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).