Sample Filter
   11 tags on

1 answer

How to create a summary table of an one2many table in OpenERP7?

I have tree models: res.partner, my_category and partner_my_category_rel. The relationship between partner and category is a many2many, but I needed to store some attributes in the relationship table ...

1 answer

C++ regex_match not working

Here is part of my code bool CSettings::bParseLine ( const char* input ) { //_asm INT 3 std::string line ( input ); std::size_t position = std::string::npos, comment; regex ...

1 answers | 1 min ago by mlgpro on Stack Overflow stackoverflow.com
2 answers

Issue in deplaying django application

I am getting "Internal Server Error" when I try to access the django website. I am using Django 1.8, Python 2.7.10, centos 6.5 and apache. In apache log I am getting the following error: mod_wsgi ...

3 answers

TortoiseGit using incorrect SSH key

I have a strange problem with tortoise git at the moment, which I can't figure out. When trying to commit to my repository on github I get the error ERROR: Permission to martindevans/Hermes.git ...

3 answers | 1 min ago by Martin on Stack Overflow stackoverflow.com
4 answers

Python: Reading thru CSV file, finding columns with same value and appending their other column values

quick logic question. If I have a CSV file that has a dictionary value for each line (with columns being ["Location"], ["Movie Title"], ["Date"]), what's the best way for me to combined the Title ...

4 answers | 2 mins ago by SpicyClubSauce on Stack Overflow stackoverflow.com
0 answers

Vector iterator not dereferencable error when trying to push_back()

I have a problem when my application crashes with this error message from VS: "Debug assertion failed! (...) Expression: vector iterator not dereferencable". The thing is, it happens during using ...

3 answers

How do I print an item and the list it came from in Python?

I am trying to create a roulette simulator and currently the program only prints the number. How do I get it to print the number and the list title it is in? Example: 12 Red 22 Black import random ...

3 answers | 3 mins ago by Micah on Stack Overflow stackoverflow.com
0 answers

build app that use libraries installed from msys2 with pacman

I try to build my app that use glib-2.0 with visual studio. The glib-2.0 was installed with pacman from msys2. So I haven't glib-2.0.lib but I have glib-2.0.a When I set glib-2.0.a and intl.a in ...

1 answer

Encoding and then decoding json with non-ascii characters in python 2.7

I have a python application that encodes some objects to json, passes the json string to another program, and then reads in a possibly modified version of that json string. I need to check that ...

0 answers

Passing vector of vectors to function

I have a function which accepts a vector<vector<MyClass>> and modifies the MyClass instances. It's been a long time since I've written any C++ and I'm having difficulty remembering ...

6 answers

Finding n-th permutation without computing others

Given an array of N elements representing the permutation atoms, is there an algorithm like that: function getNthPermutation( $atoms, $permutation_index, $size ) where $atoms is the array of ...

2 answers

Git for Windows equivalent for open current directory command

I am using the Git for Windows "git bash" command line on Windows and can't seem to find an equivalent in it for the open current directory command "cmd ." I can't find any documentation but if ...

1 answer

Upload files to folder in upload folder in Flask

I need to upload user files into their own folders within my app.config['UPLOAD_FOLDER'] folder. I'm able to upload a file to app.config['UPLOAD_FOLDER'] but can't upload to any folder in it, like ...

1 answers | 5 mins ago by Josh Usre on Stack Overflow stackoverflow.com
2 answers

create list of binary strings (Python)

I have a directed Multigraph and would like to identify the nodes with a binary string representing the coordinates of each node. How can I build a list of these coordinates depending on the dimension ...

2 answers | 5 mins ago by sebastian on Stack Overflow stackoverflow.com
0 answers

Defaulted default constructor cannot be used by non-static data member

Take a look at the code: class Outer { public: struct Inner1 { Inner1 () = default; string name {}; string comment {}; }; struct Inner2 { Inner2 () = ...

1 answer

ffmpeg cut first 5 seconds

I am having trouble removing the first 5 seconds of a .mp4 video. Here is what I have so far: subprocess.call("ffmpeg -ss 00:00:00 -t 00:00:05 -i /home/requiem/Desktop/t1.mp4 -vcodec copy -acodec ...

1 answers | 7 mins ago by requiem31 on Stack Overflow stackoverflow.com
6 answers

Python Pip install Error: Unable to find vcvarsall.bat. Tried all solutions

I tried to install Scrapy for Python 2.7.8 (anaconda 2.1.0) 32-bit using pip install scrapy And I got this error error: Microsoft Visual C++ 10.0 is required (Unable to find vcvarsall.bat). I ...

0 answers

How to call an external library function through Python script when using Jython?

I'm kinda newbie to Jython. I'm trying to execute a python script through a Java program (using Jython). Inside the python script I'm trying to call a method of some external library (called petl). ...

4 answers

C++ multiple constructor with different arguments

I have one ABC class whose constructor is taking 3 arguments e.g x1, x2 and l. One sample code is shown below. I am trying to make another constructor in the same class ABC that should take different ...

4 answers | 8 mins ago by musafir on Stack Overflow stackoverflow.com
6 answers

Can't install psycopg2 with pip in virtualenv on Mac OS X 10.7

I am following Heroku's tutorial to deploy a Django app: http://devcenter.heroku.com/articles/django#prerequisites. Everything is working fine until I get to this part: $ pip install Django ...

2 answers

Python 2.7 How to come out from … to >>>

I am a beginner. I started trying new codes. I came across conditional statements and looping. I wrote the code in python 2.7 compiler >>a=5 >>while(a<=5): ... print a I want to ...

2 answers | 11 mins ago by ksv on Stack Overflow stackoverflow.com
1 answer

matplotlib.pyplot.draw() and matplotlib.pyplot.show() have no effect

In the past I was able to do simple animations with matplotlib with a for loop, but this hasn't worked for some time now. The standard answer is that you have to turn interactive mode on and/or force ...

0 answers

Install third party libs to be available from within and without the Google App Engine dev server

The official documentation for Google App Engine with python recommends using a virtualenv and installing third party libs into a subdirectory of the project root: $ source ...

0 answers

scala groupby and sum on Observable

I am a scala beginner and I want to perform a simple groupby and sum over an Observable. For example: val test = Observable.just(("a", 1), ("a", 2), ("b", 5), ("b",3)) I would like to group by key ...

0 answers

Assembly numpy vector

How to add a numpy array A to elements of a numpy array B with indices given by an index array C? Ideally, I can write: A=np.zeros(4,float) B=np.([1,2,3,4]) C=np.([1,2,1,3]) A[C] +=C print A ...

1 answer

Trouble Understanding Signal Mapper PyQt

So I am generating a menu of options based on some files on my system. I have a list list of objects I need to dynamically generate an option in the menu for and need to be able to let the function ...

1 answers | 13 mins ago by jspada on Stack Overflow stackoverflow.com
4 answers

Parsing outlook .msg files with python

Looked around and couldn't find a satisfactory answer. Does anyone know how to parse .msg files from outlook with Python? I've tried using mimetools and email.parser with no luck. Help would be ...

4 answers | 13 mins ago by Michael on Stack Overflow stackoverflow.com
1 answer

How to find out addresses of the slots in dynamically allocated multidimensional array?

I created a 2-dimensional dynamically allocated array. Then I wanted to output the addresses of the slots, so I can really see it's not a contiguous block of memory. I've managed to do that by ...

0 answers

django-custom-user and custom_user_emailuser (does not exist)

Using django-custom-user, I've learned that I must first make a migration for custom_user before the remaining migrations will work. Fair enough. On a clean instance (just created a database and git ...

1 answer

Seaborn: how to set bar borders' line width or color?

I am trying to draw a barplot with bars with no borders. By default bars has thin black borders. In the devlopment version (0.6) of Seaborn, I could pass kwargs (linewidth, edgecolor) to pyplot.bar() ...

15 30 50 per page
1 2 3