weecology / weecology/DeepForest

main.deepforest.predict_file should be able to take in a dataframe, not just a csv file.

Open
#797 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

API good first issue
Dominant language
Python
Stars
774
Forks
265
PR merge metrics
No merged PRs in 30d

Description

Looking at the code base.

https://deepforest.readthedocs.io/en/latest/_modules/deepforest/main.html#deepforest.predict_file

it actually looks like dataset.TreeDataset() is the problem here, because utilities.read_file is definitely flexible enough. The docstring of predict_file should be updated and the argument name should be changed (but a deprecation warning added until 2.0), but its the dataset class, which the user really never sees that often that can be updated. I think this would still be considered a patch.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with deepforest.main.predict_file and dataset.TreeDataset, using the linked predict_file documentation; compare their input handling with utilities.read_file. Update the predict_file documentation and argument naming, preserve the old name with a deprecation warning, and make dataframe input work through TreeDataset.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.