René's URL Explorer Experiment


Title: Segmentation fault when running LPs repeatedly · Issue #8 · sharpbracket/python-qsoptex · GitHub

Open Graph Title: Segmentation fault when running LPs repeatedly · Issue #8 · sharpbracket/python-qsoptex

X Title: Segmentation fault when running LPs repeatedly · Issue #8 · sharpbracket/python-qsoptex

Description: Hello I am using a MAC OS Big Sur Version 11.3.1 When I run the solver multiple times SOMETIMES it segmentation faults, I dont know if this is because of qsopt_ex or because of the cython library. Just copy the code below into a file cal...

Open Graph Description: Hello I am using a MAC OS Big Sur Version 11.3.1 When I run the solver multiple times SOMETIMES it segmentation faults, I dont know if this is because of qsopt_ex or because of the cython library. ...

X Description: Hello I am using a MAC OS Big Sur Version 11.3.1 When I run the solver multiple times SOMETIMES it segmentation faults, I dont know if this is because of qsopt_ex or because of the cython library. ...

Opengraph URL: https://github.com/sharpbracket/python-qsoptex/issues/8

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Segmentation fault when running LPs repeatedly","articleBody":"Hello I am using a MAC OS Big Sur Version 11.3.1 \r\n\r\nWhen I run the solver multiple times SOMETIMES it segmentation faults, I dont know if this is because of qsopt_ex or because of the cython library. Just copy the code below into a file called `reproducing_seg_fault.py` and run the program like 20 or so times consecutively. One of the times will result in a segfault (see here) \r\n\u003cimg width=\"738\" alt=\"Screen Shot 2023-03-24 at 8 20 21 PM\" src=\"https://user-images.githubusercontent.com/5061556/227667055-e091b53e-aa03-4197-a068-489729020300.png\"\u003e\r\n\r\nCode here:\r\n\r\n```\r\nimport qsoptex\r\n\r\nimport faulthandler\r\nfaulthandler.enable()\r\n\r\n#import logging\r\n#logging.basicConfig(level=logging.NOTSET)\r\n\r\nclass Polytope:\r\n    def __init__(self, A, b):\r\n        self.A = A\r\n        self.b = b\r\n        self.status = None\r\n        \"\"\"\r\n            The status variable carries the status of a most recent solve, if it is set to None then an LP run has not occurred yet \r\n        \"\"\"\r\n        self.p = None\r\n\r\n    def dimension(self):\r\n        return len(self.A[0])\r\n    \r\n    def inequality_count(self):\r\n        return len(self.A)\r\n\r\n    #given an objective array c we attempt to maximize it and return the status, surprising the \"c\" tells us what the dimension of the problem is \r\n    def maximize(self, c, flag_integers=True): \r\n        self.p = qsoptex.ExactProblem()\r\n        for var_number in range(len(c)):\r\n            self.p.add_variable(name='x' + str(var_number), \r\n                objective=c[var_number], \r\n                lower=0, upper=1)\r\n\r\n        for constraint_number in range(self.inequality_count()):\r\n            self.p.add_linear_constraint(qsoptex.ConstraintSense.LESS, \r\n                dict(('x' + str(var_number), self.A[constraint_number][var_number]) for var_number in range(len(c))), \r\n                rhs = self.b[constraint_number], \r\n                name='c' + str(constraint_number))\r\n\r\n        self.p.set_objective_sense(qsoptex.ObjectiveSense.MAXIMIZE)\r\n        self.p.set_param(qsoptex.Parameter.SIMPLEX_DISPLAY, 1)\r\n        print(\"before seg fault: \")\r\n        self.status = self.p.solve()\r\n        print(\"after seg fault: \")\r\n\r\n\r\n    \r\n\r\nif __name__ == '__main__':\r\n\r\n    #running one at a time never results in a segfault\r\n    #running both of these repeatedly results in a segfault \r\n\r\n \r\n    A_matrix =  [[1037066, 2074132, 1648264, 796528, 1593056, 686112, 1372224, 244448, 488896, 977792, 1955584, 1411168, 322336, 644672, 1289344, 78688, 157376, 314752, 629504, 1259008], [-1037066, -2074132, -1648264, -796528, -1593056, -686112, -1372224, -244448, -488896, -977792, -1955584, -1411168, -322336, -644672, -1289344, -78688, -157376, -314752, -629504, -1259008]]\r\n    b_matrix =  [2463098, -2463098]\r\n    c_matrix =  [0, -1, 1, -1, 1, -1, 0, 0, 0, 0, -1, 0, -1, -1, 0, 1, 0, 1, 1, -1]\r\n\r\n    test_polyhedron = Polytope(A_matrix, b_matrix)\r\n    \r\n    test_polyhedron.maximize( c_matrix)\r\n\r\n    A_matrix =  [[1037066, 2074132, 1648264, 796528, 1593056, 686112, 1372224, 244448, 488896, 977792, 1955584, 1411168, 322336, 644672, 1289344, 78688, 157376, 314752, 629504, 1259008], [-1037066, -2074132, -1648264, -796528, -1593056, -686112, -1372224, -244448, -488896, -977792, -1955584, -1411168, -322336, -644672, -1289344, -78688, -157376, -314752, -629504, -1259008]]\r\n    b_matrix =  [2463098, -2463098]\r\n    c_matrix =  [0, -1, 1, -1, 1, -1, 0, 0, 0, 0, -1, 0, -1, -1, 0, 1, 0, 1, 1, -1]\r\n\r\n    test_polyhedron = Polytope(A_matrix, b_matrix)\r\n\r\n    test_polyhedron.maximize( c_matrix)\r\n```","author":{"url":"https://github.com/frogeyedpeas","@type":"Person","name":"frogeyedpeas"},"datePublished":"2023-03-25T00:21:00.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":4},"url":"https://github.com/8/python-qsoptex/issues/8"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:d460218e-6134-c46c-a796-ee50a19f0040
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idA370:21F0CB:D6FE07:125AF9C:6A63BA93
html-safe-nonce0c2f3353074551ab32779d2a684fa735106277b75e4d87b357e8ed317ff2c183
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMzcwOjIxRjBDQjpENkZFMDc6MTI1QUY5Qzo2QTYzQkE5MyIsInZpc2l0b3JfaWQiOiI2MzIwMTEyODk5NzU3MTYxMTA3IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacaa774c0e5e21670176826cab239e52a604e1a073d9eaba6d2e25f35a8d52f586
hovercard-subject-tagissue:1640235762
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/sharpbracket/python-qsoptex/8/issue_layout
twitter:imagehttps://opengraph.githubassets.com/c62ab2628ce5ce131996dfd30c66eea1c1ae37a2c02fc867b390b52e3e46d404/sharpbracket/python-qsoptex/issues/8
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/c62ab2628ce5ce131996dfd30c66eea1c1ae37a2c02fc867b390b52e3e46d404/sharpbracket/python-qsoptex/issues/8
og:image:altHello I am using a MAC OS Big Sur Version 11.3.1 When I run the solver multiple times SOMETIMES it segmentation faults, I dont know if this is because of qsopt_ex or because of the cython library. ...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamefrogeyedpeas
hostnamegithub.com
expected-hostnamegithub.com
None4c1c4f1792dfc705b5a5073fed6c61988f59766cec1277f24f55d4b876f9881c
turbo-cache-controlno-preview
go-importgithub.com/sharpbracket/python-qsoptex git https://github.com/sharpbracket/python-qsoptex.git
octolytics-dimension-user_id272925331
octolytics-dimension-user_loginsharpbracket
octolytics-dimension-repository_id28111148
octolytics-dimension-repository_nwosharpbracket/python-qsoptex
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id28111148
octolytics-dimension-repository_network_root_nwosharpbracket/python-qsoptex
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasefefaad6f0be5c33f57f42bb65ed668f74c872364
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/sharpbracket/python-qsoptex/issues/8#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fsharpbracket%2Fpython-qsoptex%2Fissues%2F8
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
Code QualityEnforce quality at mergehttps://github.com/features/code-quality
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fsharpbracket%2Fpython-qsoptex%2Fissues%2F8
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=sharpbracket%2Fpython-qsoptex
Reloadhttps://github.com/sharpbracket/python-qsoptex/issues/8
Reloadhttps://github.com/sharpbracket/python-qsoptex/issues/8
Reloadhttps://github.com/sharpbracket/python-qsoptex/issues/8
sharpbracket https://github.com/sharpbracket
python-qsoptexhttps://github.com/sharpbracket/python-qsoptex
Notifications https://github.com/login?return_to=%2Fsharpbracket%2Fpython-qsoptex
Fork 3 https://github.com/login?return_to=%2Fsharpbracket%2Fpython-qsoptex
Star 8 https://github.com/login?return_to=%2Fsharpbracket%2Fpython-qsoptex
Code https://github.com/sharpbracket/python-qsoptex
Issues 2 https://github.com/sharpbracket/python-qsoptex/issues
Pull requests 0 https://github.com/sharpbracket/python-qsoptex/pulls
Actions https://github.com/sharpbracket/python-qsoptex/actions
Projects https://github.com/sharpbracket/python-qsoptex/projects
Wiki https://github.com/sharpbracket/python-qsoptex/wiki
Security and quality 0 https://github.com/sharpbracket/python-qsoptex/security
Insights https://github.com/sharpbracket/python-qsoptex/pulse
Code https://github.com/sharpbracket/python-qsoptex
Issues https://github.com/sharpbracket/python-qsoptex/issues
Pull requests https://github.com/sharpbracket/python-qsoptex/pulls
Actions https://github.com/sharpbracket/python-qsoptex/actions
Projects https://github.com/sharpbracket/python-qsoptex/projects
Wiki https://github.com/sharpbracket/python-qsoptex/wiki
Security and quality https://github.com/sharpbracket/python-qsoptex/security
Insights https://github.com/sharpbracket/python-qsoptex/pulse
Segmentation fault when running LPs repeatedlyhttps://github.com/sharpbracket/python-qsoptex/issues/8#top
https://github.com/frogeyedpeas
frogeyedpeashttps://github.com/frogeyedpeas
on Mar 25, 2023https://github.com/sharpbracket/python-qsoptex/issues/8#issue-1640235762
https://user-images.githubusercontent.com/5061556/227667055-e091b53e-aa03-4197-a068-489729020300.png
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.