ESRI API for BAO reports in Python - python

Currently we use ESRI's Business Analyst Online (BAO) to create demographic reports based on geospatial inputs (3-mile ring around an address, or within a city's boundaries, etc.). These are generally output from the point and click web application as PDF or Excel files.
I'm trying to automate the process of retrieving those reports from ESRI BAO. I have installed the Python 3.5+ package arcgis following instructions found here. This seems to get me started with the ArcGIS functionality, but I don't see any API functionality for the BAO toolset. Is there another API package I should be downloading? Or is there documentation on a REST/SOAP API I can call from Python? I've looked over the documentation, but if there's something there about what I'm trying to do I haven't found it.
Has anybody tried to do this before and been successful? Let me know.

After starting trials for several ArcGIS services I found that ArcGIS Online provides access to ESRI's REST API. As of today, once you've signed up (either paying or with a trial) you can navigate to the ArcGIS GeoEnrichment Service Documentation. That documentation tells you everything you need to know about how to access the same reports you would find in ESRI BAO, but through a REST API.

Related

PowerBI: Refresh automation with Python

I'm trying to automate the refresh function on PowerBI Desktop (For now I don't want to pay for the Pro Licence) with Python but there are so many packages and I'm getting a bit lost. I wanted to use the win32com package first but PowerBI isn't in the application list of the package. I saw that we can use some Microsoft APIs but I don't want to use loads of ressources for this project.
Is it possible to create this automation with Python?
I accept every suggestion possible.
For information I'm using Pycharm Professional with the latest release of Python.
Thank you in advance for your help!
Just call the REST API: Refresh Dataset in Group. This article looks right: Refresh a Power BI Dataset from Python.

How to deploy or share your python program to friends

I wanted to share my python program to my friends but the problem is they will have to install python first then all the libraries which I used in order to run my program and it might be hard to do so as I have used too many libraries like 15-20 something.
MY Questions:-
Q1. How can I share my python program without making them install so much stuff?
Q2. Is there any other language on which it could be done?
Thank you.
Regards
Google Colab
You can write your python program in Google Colab and then share the notebook with others to run.
It's free to use and your dependencies can be imported or installed based on the information from this stackoverflow post.
Streamlit
Streamlit allows you to build custom web apps using python that are shareable. It's marketed use is for data science and machine learning python projects. You should check their website to see if it satisfies your specific needs.
repl.it
On the website repl.it you can create public Python projects which can even include PyPI dependencies. The user can then run and edit them, for example here: https://replit.com/#TedTaras/Monster-Hunter. Projects are public by default, private ones cost extra.

Python to Automate Fusion 360 with COM

I've searched everywhere for a solution to this problem but I haven't found it yet.
I know that Autodesk Inventor can be automated with Python using win32com package by:
win32com.client.Dispatch("Inventor.Application")
However I can't find the "prodID" that is needed to use this package with Fusion 360 and no documentation for automation ever being done this way with this package.
I need to be able to control a range of other processes so it would be ideal if I could use Python to launch Fusion 360 and perform operations without having to load the script within the application itself. Any help would be appreciated.
The Fusion 360 API is not a COM API so it's not possible to use win32com to drive it. To use the API, your program must be either an add-in or script running from within Fusion 360.

What packaging option are available for python/django

I am starting on developing a django application on a shared webhosting server(alwaysdata.com).
I would like to understand what are the packaing options available to package a django application (preferably in compiled form)
I would like to setup the source code repository on my system and build using the python packaging and deploy the package on alwaysdata.com.
I would like the option of not having to share the source code on alwaysdata.com.
Looking at pip , I am not able to find this option.
EDIT
A few more clarification: I would need the ability to not share the sourcecode since it contains the "API secret key" which I would not want to compromise. The more I look into it , the more i believe that there is no way for me to distribute binary only distribution.
I've found fabric to be a pretty nice tool for deploying Django projects. To compile your python code you can use compileall:
python -m compileall <dir>
How is this API key used? Is it a google maps api? Is it provided in scripts that go to the browser? If so, it's already out in the open, anyone using your site will see it, so you're trying to provide a $100 lock for a $0.01 piece of information. If it's a google maps api, it's not secured by keeping it hidden, but rather it's tied to a domain/directory (IIRC).
Can you share a little more what the API key is and is for, then maybe we can help you find a better solution to keep it secure.
Do you think you have to share your source code if you host your application on a 'shared hosting' provider? That's not the case. Your source code should still be private to you but the administrators of your hosting provider can get it too. Other normal Joe Users of the service shouldn't have access to your source code, or your database too. If they do, then get another shared hosting provider!

Python application decompiler

I have a website that offers files to people; this site is related to a SAT decoder based on Linux. Some people developed "plugins" written in Python that access my site and get those files directly from the decoder without visiting the site. I know I could block them by using JavaScript methods on the website but I would like to know what this plugin does first. The files of those plugins are a series of pyo files which, from what I understood, are compiled Python scripts.
Is there a way I can get the source of those files or at least see what they "call"?
I only found non-working or not free services. I mean there must be a way; people crack almost every software made by major software houses and I can't "get" what a Python script does?
Exploring and decompiling python bytecode

Categories