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

Make DALI buildable for Python 3.8 #1782

Merged
merged 1 commit into from
Mar 14, 2020

Conversation

JanuszL
Copy link
Contributor

@JanuszL JanuszL commented Mar 2, 2020

  • updates manylinux to build python 3.8.1 and remove not supported python versions
  • bumps up pybind11 version to 2.4.2
  • adjusts tests to python 3.8

Signed-off-by: Janusz Lisiecki jlisiecki@nvidia.com

Why we need this PR?

Pick one, remove the rest

  • It adds an ability to build DALI for python 3.8.x

What happened in this PR?

Fill relevant points, put NA otherwise. Replace anything inside []

  • What solution was applied:
    updates manylinux to build python 3.8.1 and remove not supported python versions
    bumps up pybind11 version to 2.4.2
  • Affected modules and functionalities:
    manylinux, pybind11
  • Key points relevant for the review:
    NA
  • Validation and testing:
    CI build
  • Documentation (including examples):
    NA

JIRA TASK: [DALI-1302]

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1163065]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1163186]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1163065]: BUILD FAILED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1163186]: BUILD FAILED

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 3, 2020

This pull request fixes 1 alert when merging b6512f468f1b97c6fe46d689f384f7a1a5769369 into 03373f9 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1165490]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1165490]: BUILD FAILED

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 3, 2020

This pull request fixes 1 alert when merging f869f74c32d2fcd20b26e4559a203b0923091d77 into 03373f9 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 3, 2020

This pull request fixes 1 alert when merging 176868e15066a2731b69cbece16263c655062660 into 03373f9 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1165588]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1165588]: BUILD FAILED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1165708]: BUILD STARTED

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 3, 2020

This pull request fixes 1 alert when merging 287c9be591cffc51137e2ff7b9b3286b6cfedc4d into 03373f9 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1165708]: BUILD FAILED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1166066]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1166066]: BUILD FAILED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1167254]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1167254]: BUILD FAILED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1169221]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1169221]: BUILD FAILED

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 5, 2020

This pull request fixes 1 alert when merging 5b38aa99f7c49cbd302737c60d59538466c59207 into 4735a26 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 5, 2020

This pull request fixes 1 alert when merging 2bbc59a3481fccbf3654944f01f8cf7869d9c325 into 4735a26 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@JanuszL JanuszL force-pushed the update_python_builds branch 2 times, most recently from 80c59b4 to c8bf59e Compare March 5, 2020 11:17
@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 10, 2020

This pull request introduces 1 alert and fixes 1 when merging c0f6709ea9b4f33ec8fc812c830e124ff328c9be into 01452f5 - view on LGTM.com

new alerts:

  • 1 for Unused import

fixed alerts:

  • 1 for Unused import

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1180895]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1180896]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1180897]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1180895]: BUILD PASSED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1180896]: BUILD PASSED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1180897]: BUILD PASSED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1181805]: BUILD STARTED

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 11, 2020

This pull request introduces 1 alert and fixes 1 when merging 5c690bcf9220ec2a8e7a9f05ce6f2842fcda965d into 01452f5 - view on LGTM.com

new alerts:

  • 1 for Unused import

fixed alerts:

  • 1 for Unused import

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1181805]: BUILD PASSED

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 11, 2020

This pull request fixes 1 alert when merging b2e1204b86cd6a795bec6955c129dd82ebba12c0 into 03b9368 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1184134]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1184134]: BUILD PASSED

@@ -90,7 +90,7 @@ def check_videopipeline_supported_type(dtype):
del pipe

SUPPORTED_TYPES = [types.DALIDataType.FLOAT, types.DALIDataType.UINT8]
ALL_TYPES = [v for k, v in types.DALIDataType.__dict__.items() if not re.match("__(.*)__", str(k))]
ALL_TYPES = [v for k, v in types.DALIDataType.__dict__.items() if not (re.match("__(.*)", str(k)) or re.match("name", str(k)))]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

list(types.DALIDataType.__members__.values()) to be precise

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@@ -3,6 +3,9 @@ pip_packages=""
target_dir=./docs/examples/use_cases/tensorflow/resnet-n

do_once() {
if [ $($topdir/qa/setup_packages.py -n -u tensorflow-gpu --cuda ${CUDA_VERSION}) = -1 ]; then
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar check is in the qa/test_template.sh

Can we maybe add an arg to setup_packages.py, that returns true/false depending whether we have anything to install or not?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In test_template.sh negative value is fine, for i in seq 0 $last_config_index; is just noop in this case. The only thing we do there is to make sure that last_config_index it not set to 0 when is negative and one_config_only was set.

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 13, 2020

This pull request fixes 1 alert when merging 3b736010b43633a07ae5a2a89847a9a45edd617e into 452b359 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

def get_key_with_cuda(key, val_dict, cuda):
"""Get get set of versions for highest matching cuda version available.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"""Get get set of versions for highest matching cuda version available.
"""Get the set of versions for highest matching cuda version available.

nitpicking

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@@ -177,8 +230,11 @@ def main():
elif args.getall:
print(get_all_strings(args.use, args.cuda))
elif args.install >= 0:
if args.install > cal_num_of_configs(args.use, args.cuda):
if args.install > cal_num_of_configs(args.use, args.cuda) or args.install < 0:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are in branch where args.install >= 0, it can't ever satisfy the or args.install < 0 clause.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Comment on lines 102 to 103
def test_request(req, name, cuda):
"""Check if given url to a package is avialable"""
Copy link
Contributor

@klecki klecki Mar 13, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
def test_request(req, name, cuda):
"""Check if given url to a package is avialable"""
def test_request(py_ver, url, cuda):
"""Check if given `url` to a package of version `py_ver` is avialable"""

If you are already touching this, but I won't insist.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link
Contributor

@klecki klecki left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The setup_packages.py is getting a bit out of hand, but we agree that it's out of scope for this PR.

- updates manylinux to build python 3.8.1 and remove not supported python versions
- bumps up pybind11 version to 2.4.2
- adjusts tests to python 3.8

Signed-off-by: Janusz Lisiecki <jlisiecki@nvidia.com>
@lgtm-com
Copy link
Contributor

lgtm-com bot commented Mar 13, 2020

This pull request fixes 1 alert when merging b1fef70 into 452b359 - view on LGTM.com

fixed alerts:

  • 1 for Unused import

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1188857]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [1188857]: BUILD PASSED

@JanuszL JanuszL merged commit eef3c02 into NVIDIA:master Mar 14, 2020
@JanuszL JanuszL deleted the update_python_builds branch March 14, 2020 03:11
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

Successfully merging this pull request may close these issues.

None yet

4 participants